How to update/view records of a flat file with packed decimal fields?

195 pts.
Tags:
AS/400
AS/400 DB2
Using RUNQRY, it shows the values in packed format that are hard to understand/decrypt for a human.
1

Answer Wiki

Thanks. We'll let you know when a new response is added.

Why use RUNQRY if it is a flat file as there are no individual fields. You best option is the DSPPFM mentioned by Splat. Your other option is to use a program or app use substring to parse out the data so it is easier to work with.

Discuss This Question: 3  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • Splat
    Using DSPPFM, you can use F10 then F11 to view the hexadecimal code to see the contents of the packed decimal data (knowing the positions of the data is useful).
    12,915 pointsBadges:
    report
  • RossHowatson
    One option is to create a file layout (think System 36 IDDU) for the flat file and then link the data definition to the file in question. Once linked (it will not cause a file level check) you can use Query/400 to see the formatted data. If the file has multiple record types then IDDU will work for this as well.
    630 pointsBadges:
    report
  • ToddN2000
    Your biggest problem is trying to update the packed data in a flat file. You are safer trying to write a program or an app that will do the job.
    134,495 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.

Following

Share this item with your network: