But in order to use MERGE, the records in DSNAME1 would have to already be in sorted order by the key, and the records in DSNAME2 would have to already be in sorted order by the key. With SORT, the records in DSNAME1 and DSNAME2 can be in any order.
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: