|
Am 03.02.2026 um 15:30 schrieb Vern Hamberg via MIDRANGE-L <midrange-l@xxxxxxxxxxxxxxxxxx>:
Hi Jim
I sometimes use the POSSTR function to get where a string is, along with adding to the returned value to get the end or start of the next thing.
Now if values and all are broken apart and on different rows, maybe you could put them back together with LISTAGG. That function does need something on each row to identify what should go together.
*Regards*
*Vern Hamberg*
IBM Champion 2025 <cid:part1.U4VznBDg.CfM1fKGm@centurylink.net> CAAC (COMMON Americas Advisory Council) IBM Influencer 2023
On 2/3/2026 8:11 AM, Jim Franz wrote:--
I'm trying to select the value from a log file which holds part of large
json rows, but the json incomplete and not readable so the "status" never
in same position. I need the value of status.or even the whole string
"status":"Paid"
(scan and substring may be wrong description)
sample data
"status":"Paid","allow
],"status":"Declined",
I can picture this in RPGLE but trying to improve my sql...
Found solutions online but not DB2.
Jim Franz
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: https://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives
at https://archive.midrange.com/midrange-l.
Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription related questions.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2026 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.