Can i read output file created after SORTing in the same program.
SORT WORK-FILE ON ASCENDING KEY SORT-KEY USING INPUT-FILE GIVING OUTPUT-FILE.
Is there any way, I can read sorted out OUTPUT-FILE in the same program after creating it.
Thank you.
Can i read output file created after SORTing in the same pgm
-
- Posts: 27
- Joined: Sun Aug 16, 2009 11:07 pm
- Skillset: cobol, db2, application performance tuning
- Referer: SEARCH
- Location: St. Cloud, Minnesota
Re: Can i read output file created after SORTing in the same
Have you tried to open the file as input after the sort ?
-
- Posts: 474
- Joined: Thu Mar 10, 2016 5:03 pm
- Skillset: assembler rexx zOS ispf racf smf
- Referer: saw it in the experts foprum thought I could help here
Re: Can i read output file created after SORTing in the same
With DFSORT your SORTOUT can be the dataset as SORTIN, so yes.
- sergeyken
- Posts: 458
- Joined: Wed Jul 24, 2019 10:12 pm
- Skillset: Assembler, JCL, Utilities, PL/I, C/C++, DB2, SQL, REXX, COBOL, etc. etc. etc.
- Referer: Internet search
Re: Can i read output file created after SORTing in the same
savitha_y wrote:Can i read output file created after SORTing in the same program.
SORT WORK-FILE ON ASCENDING KEY SORT-KEY USING INPUT-FILE GIVING OUTPUT-FILE.
Is there any way, I can read sorted out OUTPUT-FILE in the same program after creating it.
Thank you.
There is nothing special for SORT, or any other program.
Any output DATASET(!) can be opened for input in the same, or any other program, in the same, or any other job step, in the same, or any other job, provided the output dataset has been properly CLOSED after its creation.
That’s it. These are basics of zOS/MVS/...
Javas and Pythons come and go, but JCL and SORT stay forever.
Re: Can i read output file created after SORTing in the same
Thank you all for your response. I tried it and it is working fine.
-
- Similar Topics
- Replies
- Views
- Last post
-
- 24
- 4645
-
by Pedro
View the latest post
Wed Jan 04, 2023 5:59 am
-
-
File Handling 3 input files and 1 output file by using EZT
by pavan426 » Thu Sep 09, 2021 12:17 am » in CA-Easytrieve - 0
- 4419
-
by pavan426
View the latest post
Thu Sep 09, 2021 12:17 am
-
-
- 2
- 1444
-
by naga821
View the latest post
Fri Oct 28, 2022 7:31 pm
-
- 2
- 4008
-
by zbius
View the latest post
Wed Nov 06, 2024 2:16 pm
-
- 2
- 2741
-
by willy jensen
View the latest post
Sat Mar 04, 2023 12:41 pm