|
rpg400-l-request@xxxxxxxxxxxx wrote: > 4. Re: RPGLE pgm to parse a string (Stiju Easo) > >I asked for reverse of string bcoz i can take values b/w 2nd and 3rd '_' 's >flatly >then reverse obtained string > >The problem with earlier post is ,how can i correctly gusses a charecter >just after third but last '_' , it is error prone, otherwise that logic is >good > >Any one plse guide me, is there any way other than reversing string? I _think_ your request is something like this... Say you have three records and the field in those records shows: 1 A123_B_C_D_E_F_G 2 A_B_C123_D_E_F_G_H_I_J 3 A_B_C_D_E123_F123_G_H You want to extract: 1 E 2 H 3 F123 ...from those three records. Also, maybe the third one should be '321F', I'm not sure about that part at all. The field is variable length and the substrings are variable length. There is a variable number of substrings in the field. But you know that you want the third substring from the end of the field. Am I close? Tom Liotta
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.