|
Davidx'000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E3FFF'
I really don't think SQL is the tool for this - if this is about
replacing non-displayable characters. You would be better off using the
%xlate function, I think. It is useful for simple case conversion, but
you could set up 2 constants - the first would be something like
and the other would be all blanks and the same length - remember thathex 40.
the above value is in HEX, so it is 2 hex digits for each "character" or
byte - you need the same number of blanks as there are bytes above. Then
use %xlate - I don't have the exact syntax right in my head - get the
ILE RPG manual. %xlate will do the read through the entire string and do
the replace for you.
I do hope there is an easier way!!
HTH
Vern
David FOXWELL wrote:
This will show the first position and all rows containing the value
list--
SELECT locate( X'40', myfield, 1), myfield FROM myfile WHERE
locate( X'40', myfield)>0
How can I find hex values less that 40?
Thanks
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
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.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.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 on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.