- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi, im new to sas macros. how would I go about creating a macro to do the following:
# Does the comparison table have all columns present in the base dataset?
# Does the comparison table have any columns not present in the base dataset?
# Are corresponding columns between tables of the same data type?
# Are corresponding character columns of the same length?
# Do the tables have the same number of records?
any help is appreciated!
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Without question, here is the right way to get started.
Cut out the macros.
Write a program that does all of this for two data sets, hard-coding the data set names.
Once you have working code, you can begin to think about how to change that to a macro.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Tip 1, use Base SAS.
Tip 2, use the appropriate procedure:
Proc compare is specifically designed to do these comparisons.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content