Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Sorting a PS

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
lokesh_try8

New User


Joined: 30 Dec 2005
Posts: 14
Location: Chennai

PostPosted: Thu Feb 16, 2006 8:07 pm    Post subject: Sorting a PS
Reply with quote

Hi,
Can anyone help me out in sorting a PS file , by giving a TSO command which can in turn be used in REXX.

Thanks & Regards ,
Lokesh R icon_biggrin.gif
Back to top
View user's profile Send private message

Dariusz
Warnings : 1

New User


Joined: 11 Aug 2005
Posts: 27
Location: POLAND

PostPosted: Thu Feb 16, 2006 8:18 pm    Post subject: Why TSO ?
Reply with quote

Hi.
For not very big file and simple key we can sort the file during EDIT:

on command line set sort start_column end_column.

For big or very big file we use batch sort usuelly.

Regards.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Thu Feb 16, 2006 8:31 pm    Post subject: Re: Sorting a PS
Reply with quote

You need to allocate your input dataset to SORTIN, your output dataset to SORTOUT (they can be the same dataset, if you wish), and your terminal or DUMMY to SYSOUT:
Code:

TSO ALLOC DD(SORTIN) DA(my.dataset) SHR REU"
TSO ALLOC DD(SORTOUT) DA(my.dataset) SHR REU"
TSO ALLOC DD(SYSOUT) DA(*) REU"


Then, call the SORT program:
Code:

TSO CALL *(SORT)


Use your terminal (i.e. the SYSIN DD) to enter your SORT commands, then end the input stream with a slash/asterisk (/*):
Code:

  SORT FIELDS=(1,8,BI,A,10,6,BI,D)
/*             
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 -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Sorting of hex values Saurabh_mi DFSORT/ICETOOL 11 Thu May 25, 2017 3:49 pm
No new posts Sorting group data rajella DFSORT/ICETOOL 4 Sun Jan 22, 2017 11:32 pm
No new posts Efficient sorting chandracdac DFSORT/ICETOOL 5 Sat Oct 22, 2016 3:23 am
No new posts Stripping and Sorting of VB file G SRINIVASA RAO SYNCSORT 5 Wed Sep 14, 2016 1:34 pm
No new posts DFSORT sorting only specific records akodakka DFSORT/ICETOOL 4 Thu Aug 04, 2016 11:24 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us