View previous topic :: View next topic
|
Author |
Message |
feng hao
New User
Joined: 26 Mar 2008 Posts: 44 Location: China
|
|
|
|
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 |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
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 |
|
|
feng hao
New User
Joined: 26 Mar 2008 Posts: 44 Location: China
|
|
|
|
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 |
|
|
Frank Yaeger
DFSORT Developer
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
|
|
|
|
Yes, work data sets are NOT dynamically allocated or used for a COPY application. |
|
Back to top |
|
|
|