I want to use SORT utility and OMIT some records depending on the condition and have those omitted records in one sequential file for usage in the future. Normally if we omit records, is there any method to have those records in a file. In what way we can do this?
As you mentioned is correct, we can get the OMITed records by mentioning INCLUDE in both steps but, if for example u r giving
Condition as 'EQ' in first step just replace 'EQ' as 'NE' in second.
Here is another example Which will give me the same result using only single Step.
If u r using INCLUDE for file 2 as well use reverse logic, which is used for file 1.
If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from: