Elardus Engelbrecht wrote on 02/09/2009 04:52:51 AM: > Where is it documented that the sequence of sort control statement does > play a role in performance? My searches on Google, IBM-MAIN and DFSORT > couldn't produce something 'hard and fast'... > > My gut feeling is that > > INCLUDE COND=(1,8,CH,EQ,C'ABCDEFGH') > SORT FIELDS=(1,8,CH,A) > > is better over this > > SORT FIELDS=(1,8,CH,A) > INCLUDE COND=(1,8,CH,EQ,C'ABCDEFGH') > > for very LARGE input. > > Is this true or false? (If false, I can always do a COPY with > INCLUDE and then > do my SORT FIELDS)
It's false. The INCLUDE statement is processed before the SORT statement regardless of the order in which you specify them. For a figure showing the order of processing of DFSORT control statements, see: http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA30/FIGSTMTSEQ?SHELF=&DT=20080528171007&CASE=&ScrollTOP=FIGSTMTSEQ#FIGSTMTSEQ Note that OUTFIL INCLUDE is processed after SORT so that would be less efficient than using an INCLUDE statement which is processed before SORT. Frank Yaeger - DFSORT Development Team (IBM) - [email protected] Specialties: FINDREP, WHEN=GROUP, DATASORT, ICETOOL, Symbols, Migration => DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort/ ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html

