I'm pretty sure that trace i would have sped up the problem resolution, as Walt 
suggested.

________________________________________
From: IBM Mainframe Discussion List <[email protected]> on behalf of 
Paul Gilmartin <[email protected]>
Sent: Thursday, April 27, 2023 12:39 PM
To: [email protected]
Subject: Re: TSO Rexx C2X Incorrect Output

On Thu, 27 Apr 2023 10:39:44 -0500, Walt Farrell wrote:

>On Thu, 27 Apr 2023 10:01:06 -0400, David Spiegel wrote:
>
>>Had I thought (originally) that "Pull" was the issue,. I would've
>>figured it out on my own.
>
>Using the tracing functions in REXX to do the debugging, rather than browsing 
>the data set itself, would also have been helpful.
>
Wouldn't that have shown mostly unintelligible character representation of 
binary/packed data?

> created=C2x(Substr(dcollect.i,105,4))

The problem was very nearby.  C2X() operated correctly on incorrect input.
Unfortunately, REXX provides little means to verify binary data other than
C2X() which was already under suspicion.  My inclination (admittedly post facto)
would be something like:
    call charout 'tempfile', dcollect.i, 1
    address SH 'od -tx1 tempfile

... using a different utility for hex conversion of the immediately proximate 
input to C2C().

--
gil

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to