130 pts.
 How to format a flat file using customised FMTSRC
Hi, I have a falt file.i want to sort it using a customised format source file.Please tell me how to create a source file for formatting the flat-file.I want the sample of a DDS of sort.

Software/Hardware used:
as400
ASKED: October 6, 2010  6:22 AM
UPDATED: October 6, 2010  11:36 PM

Answer Wiki:
first you need to create a source member to store the sort soecs. We use QFMTSRC here is the contents of a member ACHSRC and the FMTDTA command from the CL program. <pre> HSORTR 29A X FNC 95 113 FNC 124 133 FDC 1 133 FMTDTA INFILE((*LIBL/ACHNEW)) OUTFILE(*LIBL/ACHNEW) + SRCMBR(ACHSRC) OPTION(*NOPRT *NOSECLVL)</pre>
Last Wiki Answer Submitted:  October 6, 2010  1:09 pm  by  CharlieBrowne   32,785 pts.
All Answer Wiki Contributors:  CharlieBrowne   32,785 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

At the moment, I can’t find a decent link to describe source statements for the Sort (FMTDTA) command. The best that I can find is in SEU help text.

Create a source member with type SRT, SRT38 or SRT36. Each one has different SEU line prompts, but they all tend to work out the same.

When you start a SEU edit session over the source member, type “IP?” in the sequence number field to request a list of valid input prompt types.

  • A SRT member shows ‘REFORMAT/SORT’ prompts of RH,RR,RFand RC.
  • A SRT38 member shows ‘REFORMAT’ prompts of RH,RR and RF.
  • A SRT36 member shows ‘SORT’ prompts of SH,SR,SC and SF.

Choose each of the prompt types for the type of member that you created. When the prompt is displayed in the SEU edit window, press <F1> to see the help for each field in that specification type. Press <F2> to see the extended help for the entire specification type. Press <F14> to print a copy of the help that is being displayed.

By printing the extended help for all of the prompt types, you will have a simple set of documentation. That all I can give unless I can track down the old manuals on-line.

Tom

 107,765 pts.

 

Try this:

    publib.boulder.ibm.com/iseries/v5r1/ic2924/books/c0918260.pdf

The other Phil

 940 pts.