Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
CAN I SORT ONE PS FILE AND STORE INTO ONE PS FILE?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
jspaulpeter

New User


Joined: 25 Aug 2005
Posts: 12

PostPosted: Thu Jan 12, 2006 8:31 pm    Post subject: CAN I SORT ONE PS FILE AND STORE INTO ONE PS FILE?
Reply with quote

HAI FRIENDS I HAVE ONE DOUBT ?
CAN I SORT ONE PS FILE AND STORE INTO ONE PS FILE?[/b]

Title changed from "JCL SORT" to "CAN I SORT ONE PS FILE AND STORE INTO ONE PS FILE?" : Priyesh.
Back to top
View user's profile Send private message

priyesh.agrawal

Senior Member


Joined: 28 Mar 2005
Posts: 1452
Location: Chicago, IL

PostPosted: Thu Jan 12, 2006 8:41 pm    Post subject: Re: JCL SORT
Reply with quote

Quote:
CAN I SORT ONE PS FILE AND STORE INTO ONE PS FILE?

Yes, you can.

Code:
//STEP01     EXEC SORT                               
//SORTIN   DD DSN=HLQ.INPUT,DISP=SHR   
//SORTOUT  DD DSN=HLQ.OUTPUT,
//            DISP=(NEW,CATLG,DELETE)             
//SYSIN    DD *                                   
   SORT FIELDS=....
//                                                 


Fill up parameters acc to ur need... or get back in case of any problem...

Regards,

Priyesh.
Back to top
View user's profile Send private message
Gautam512

Active User


Joined: 05 Oct 2005
Posts: 309
Location: Vizag / US

PostPosted: Thu Jan 12, 2006 8:41 pm    Post subject: Re: JCL SORT
Reply with quote

Yes U can do that......
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Thu Jan 12, 2006 9:09 pm    Post subject:
Reply with quote

I think the question is whether the sort can do with one file (input and output the same one). This can be done. The intermediate results of the sort are in sortwk. So:

//sortin dd dsn=file-x,disp=shr
//sortout dd dsn=file-x,disp=shr
//sortwk01 dd dsn=&&sort1,disp=(...etc)
//sortwk03 dd dsn=&&sort2.......
//and as many sortwk files as you need more...

After the sort your input is resorted in the same file.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Compare yesterday's date to the one o... migusd SYNCSORT 8 Fri Sep 22, 2017 11:35 pm
No new posts Difference in SORT & ICETOOL Mohan Kothakota DFSORT/ICETOOL 5 Fri Sep 22, 2017 4:56 pm
No new posts Split 1 file into 10 output Files - S... Prasanth Kumar SYNCSORT 5 Sat Sep 16, 2017 12:02 am
No new posts OC4 in SORT Mohan Kothakota DFSORT/ICETOOL 2 Tue Sep 12, 2017 6:30 pm
No new posts BUILD OUTFIL based on condition other... balaji81_k DFSORT/ICETOOL 13 Fri Sep 08, 2017 11:06 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us