DSPF: Declare in display file

30 pts.
Tags:
Display File
DSPF
RPG/400
I have a field in the display file of length 13 Characters long. The first 4 characters contains the year, followed by a hyphen, Next 2 characters contain the location(alphanumeric) followed by hyphen Last 5 characters contains numeric. How do I declare in the display file. When I enter a value in this field it should be updated in the file in the same way.

Answer Wiki

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

Hi,

You have 2 basic options :-

1. Declare the field as 13 characters long and validate the data in your RPG program.
2. Declare the field as 3 separate fields, move them to the correct positions in your RPG program.

Regards,

Martin Gilbert.

Discuss This Question: 1  Reply

 
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.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Satsho
    For the display file use the EDTWRD and if needed the EDTMSK Like Martin suggests, create a 13 char field preferably via a data structure with 3 separate fields having their own validation.
    1,245 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.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

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

Following