MIDRANGE dot COM Mailing List Archive



Home » MIDRANGE-L » June 2008

RE: Need help with SQL SET statement



fixed

Alan, I am getting error message "Row not found for UPDATE."

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx]On Behalf Of Alan Shore
Sent: Thursday, June 26, 2008 12:34 PM
To: Midrange Systems Technical Discussion
Subject: RE: Need help with SQL SET statement



I believe its because you cannot update part of a field
Try
UPDATE MYLIB/MFFILE SET myFLD = substr(myFLD,1,5)|| '0000 '
where substr(myFLD,6,8) =' '


The character || is concatenation. NOTE there are 4 blanks after the 4 0's


Alan Shore
Programmer/Analyst, Direct Response
E:AShore@xxxxxxxxxxx
P:(631) 244-2000 ext. 5019
C:(631) 880-8640
"If you're going through Hell, keep going" - Winston Churchill



"Shaheen Ahmed"
<Syed.Ahmed@usamo
bility.com> To
Sent by: "Midrange Systems Technical
midrange-l-bounce Discussion"
s@xxxxxxxxxxxx <midrange-l@xxxxxxxxxxxx>
cc

06/26/2008 01:28 Subject
PM RE: Need help with SQL SET
statement

Please respond to
Midrange Systems
Technical
Discussion
<midrange-l@midra
nge.com>






Roger,

UPDATE MYLIB/MFFILE SET substr(myFLD,6,4) ='0000'
where substr(myFLD,6,8) =' '

This is not working. Got error message "Token ( was not valid. Valid
tokens: =. "

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx]On Behalf Of Reger, Bill
Sent: Thursday, June 26, 2008 12:10 PM
To: 'Midrange Systems Technical Discussion'
Subject: RE: Need help with SQL SET statement


UPDATE MYLIB/MFFILE SET substr(myFLD,6,4) ='0000'
where substr(myFLD,6,8) =' '

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.






Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2014 by MIDRANGE dot COM and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available here. If you have questions about this, please contact