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
 

 

Can we tell DFSORT the input dataset is already sorted?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
feng hao

New User


Joined: 26 Mar 2008
Posts: 44
Location: China

PostPosted: Tue Dec 22, 2009 12:36 pm    Post subject: Can we tell DFSORT the input dataset is already sorted?
Reply with quote

I used ICETOOL's select operator and I found it would sort in advance by the the 'ON(key)' before it do the subsequent real select operaton.

Then, my question is, could we tell DFSORT when we invoke it that the input dataset is already sorted correctly and it could do the real selection work directly?

Though I don't know the detail operation undergoing, I think it must save time and space when dealing with huge datasets.

Best regards!
Back to top
View user's profile Send private message

Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Tue Dec 22, 2009 9:15 pm    Post subject:
Reply with quote

If the input records are already in sorted order by the ON fields, you can tell DFSORT to do a copy instead of a sort by using OPTION COPY. For example:

Code:

...
//TOOLIN DD *
SELECT ... USING(CTL1)
//CTL1CNTL DD *
   OPTION COPY


A copy operation is generally more efficient than a sort operation.
Back to top
View user's profile Send private message
feng hao

New User


Joined: 26 Mar 2008
Posts: 44
Location: China

PostPosted: Wed Dec 23, 2009 11:53 am    Post subject:
Reply with quote

Hi, Frank,

It works after adding 'option copy'. I found that 16 sortwk* are not allocated again and elapsed time has decreased from 2.64s to 0.82s!!!
There is no difference in the storage size both below and above the line, however, that is not the topic here.

Thanks very much, Frank!
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Wed Dec 23, 2009 9:01 pm    Post subject:
Reply with quote

Yes, work data sets are NOT dynamically allocated or used for a COPY application.
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 -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Fileaid 2 commands instream work. In ... descann Compuware & Other Tools 2 Tue May 16, 2017 3:31 pm
No new posts Replace values in the input data Vikas Maharnawar DFSORT/ICETOOL 10 Thu May 11, 2017 2:18 pm
No new posts To find out size allocated to a seque... ashek15 JCL & VSAM 15 Thu Apr 27, 2017 9:42 am
No new posts LISTCAT on a dataset with symbolic pa... shreya19 JCL & VSAM 5 Fri Apr 07, 2017 5:43 pm
No new posts DFSORT - Overriding default option TU... Steve Ironmonger DFSORT/ICETOOL 3 Tue Apr 04, 2017 3:54 pm


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