The bit of code you have pasted is part of the SELECT. As Frank explained, the FIRST controls the elimination of the duplicates.
Did you read this suggestion Frank posted:
If you comment out the SORT operator (* SORT FROM...), the job will run with just the SELECT operator. You can then look at the output and you'll see what I'm doing with the sequence numbers.
Suggest you try this when you are logged on again on Monday. It will make the process more clear to you.
Do you understand this explanation?
Basically I'm giving all of the CCCC records a sequence number of 0 so they will be treated as duplicates, and all of the other records a unique sequence number so they won't be treated as duplicates. The second sequence number is used to get the records back in their original order.
As i mentioned, this will be more clear when you can see the output from the SELECT.