Had forgot about that - it does the trick and beautifully! Here's the result -

when substr(chr1,length(chr1),1) between '0' and '9' then 1
else -1
end *
substr(chr1,1,length(chr1)-1) concat
lor(x'F0', substr(chr1,length(chr1),1))
FROM vern/chrtozon

The CASE construct determines the sign.

The LOR forces the final character to a positive number.

So it's the sign times the absolute value - which would not be usable here, I suppose.


BTW, I'll be in Rochester mid-November - maybe can get together.


CRPence wrote:
The LAND [Logical AND] scalar? I referenced that [there are other logical operators] on a similar subject:

Regards, Chuck

Vern Hamberg wrote:
Yeah, just did an RTFM - wishful thinking this morning before
going to work. Sigh!!

Later Vern

rob@xxxxxxxxx wrote:
There is no BITAND yet available in SQL for DB2 for i. Submit
a DCR and see what happens.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2020 by 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 on our policy page. If you have questions about this, please contact [javascript protected email address].