AS400 COBOL one pf have one lf but key fields are different

350 pts.
Tags:
AS/400
AS400 physical file
COBOL
COBOL/400
i have one physical file,that pf have one logical file,but pf have 4 key fields,logical file have 2 key fields,now both(pf,lf) are using in cobol/400 code

 

SELECT pf-file ASSIGN TO DATABASE-pf1 [Br _extended="true" />ACCESS IS dynamic[Br _extended="true" />ORGANIZATION IS INDEXED [Br _extended="true" />RECORD KEY IS EXTERNALLY-DESCRIBED-KEY [Br _extended="true" />FILE STATUS IS pf-STATUS. [Br _extended="true" />[Br _extended="true" />SELECT lf-file ASSIGN TO DATABASE-lf1 [Br _extended="true" />ACCESS IS DYNAMIC [Br _extended="true" />ORGANIZATION IS INDEXED [Br _extended="true" />RECORD KEY IS EXTERNALLY-DESCRIBED-KEY [Br _extended="true" />FILE STATUS IS lf-STATUS. [Br _extended="true" />[Br _extended="true" />FD pf-file [Br _extended="true" />LABEL RECORDS ARE STANDARD. [Br _extended="true" />01 F4111LD-RECORD-SRC. [Br _extended="true" />COPY DDS-ALL-FORMATS OF pf1. [Br _extended="true" />[Br _extended="true" />FD lf-file [Br _extended="true" />LABEL RECORDS ARE STANDARD. [Br _extended="true" />01 F4111LI-RECORD-SRC. [Br _extended="true" />COPY DDS-ALL-FORMATS OF lf1.

 

but i got error in cobol/400 those fields are previouly defined

how to solve this

[Br _extended="true" />[Br _extended="true" />



Software/Hardware used:
software

Answer Wiki

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

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
  • TomLiotta
    but i got error in cobol/400 those fields are previouly defined Where did you get the error? What statement gave the error? Since you COPY formats of both the physical and the logical files, it's likely that the record formats will have the same names. Also, various fields in those record formats will probably have the same names. Under the two FDs, you have given 01-level items that have unique names. When you reference fields in either file, the field names need to be qualified with the 01-level name in order to make your field references unique. Tom
    125,585 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