Or, if you absolutely, positively want/need to keep the output in the dataset you initially created, simply change the JCL to use the GDG you created in the IDCAMS step as the input dataset to the COPY.
Rex -----Original Message----- From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On Behalf Of David Betten Sent: Tuesday, January 22, 2008 8:54 AM To: IBM-MAIN@BAMA.UA.EDU Subject: Re: DFSORT anomaly? I haven't seen any job output yet but I wanted to share this information from DFSORT Application Programming Guide *** For a copy application, the SORTIN data set should not be the same as the SORTOUT data set or any OUTFIL data set because this can cause lost or incorrect data or unpredictable results. *** Frank probably knows more about this but it makes sense to me why we could have problems for COPY. When we do a SORT, all of the records from SORTIN need to be read before we can write anything to SORTOUT. This is because that last record read could potentially be the first record written. However, when we do a COPY, we can start writing to SORTOUT immediately. I would just try changing your sort step to write a new dataset and see what the results are. Have a nice day, Dave Betten DFSORT Development, Performance Lead IBM Corporation email: [EMAIL PROTECTED] 1-240-715-4655, tie line 268-1499 DFSORT/MVSontheweb 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