Comparing 2 SAS® Data Sets: An Alternative to Using PROC COMPARE
While PROC COMPARE is a useful tool, it can also be intimidating. There are dozens of options to be aware of and the output has several sections. If you were interested in doing a simple comparison, wouldn't it be great if there was a simple tool to do it? Well there is! This paper presents a set of two macros that will get the job done. Using a simple merge statement and the ability of the macro facility to access both base SAS and macro functions, the algorithm compares two SAS data sets and presents the differences in an organized fashion. This can be especially useful when the same data set is changing over time, such as cumulative transfers of data occurring several times during the life of a project.