View previous topic :: View next topic
|
Author |
Message |
paduchuri
New User
Joined: 03 Jan 2011 Posts: 32 Location: Hyderabad
|
|
|
|
Hi Every one,
Code: |
SORT FIELDS=(1,6,CH,A),EQUALS
SUM FIELDS=NONE,XSUM |
I saw above code in my production control card,
some one please explain the functionality of the EQUALS option
I guess there is no need of using equals in above case.will in effect in the above case ? will the performence degrade in the above case? |
|
Back to top |
|
|
sqlcode1
Active Member
Joined: 08 Apr 2010 Posts: 577 Location: USA
|
|
|
|
paduchuri,
Read about options here
Quote: |
I guess there is no need of using equals in above case.will in effect in the above case ? |
It may/can effect output. Run the same card with 2 input data shown below and observe output in each case.
However, looks like you have Syncsort installed at your shop.
Code: |
AAAAAA01
AAAAAA02
AAAAAA03 |
Code: |
AAAAAA03
AAAAAA02
AAAAAA01 |
Thanks, |
|
Back to top |
|
|
jerryte
Active User
Joined: 29 Oct 2010 Posts: 203 Location: Toronto, ON, Canada
|
|
|
|
The EQUALS option will ensure that if two or more records have the same sort key values then the order of those records is preserved. This could require extra processsing cost since it has to keep track of the order. Avoid it if possible.
In the sample code given the EQUALS will ensure that the first record of a matching set is kept while any other matching records are written to the XSUM dataset. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19243 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
This could require extra processsing cost since it has to keep track of the order. |
Very little additional cost is needed to do this. . . |
|
Back to top |
|
|
paduchuri
New User
Joined: 03 Jan 2011 Posts: 32 Location: Hyderabad
|
|
|
|
Thanks for the information guys. |
|
Back to top |
|
|
|