BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Jay_TxOAG
Quartz | Level 8

I was lucky enough to attend SAS Macro I and II classes to get a good foundation....but the best advice I received about using macros is: Write it first without macros...just duplicate your code as much as is necessary to get it to work....then go back and put in the macro code a little at a time. Honestly, you can learn a lot from SAS's site and using Google...stay with it. Good luck

data_null__
Jade | Level 19

Are the fields the same or similar for all files?

Do you know the field names and data types?

Do you want a single data set in the end. (assuming common fields)?

This paper http://www.lexjansen.com/pharmasug/2011/tt/pharmasug-2011-tt04.pdf includes an example program to read any number of files with common fields.  The fields don't have to exist in all files nor be in any particular column but you do have to to know the field names you want to read and define them as to type.  In other words you will need to know something about the data you are reading but there is no quessing as with PROC IMPORT.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 16 replies
  • 8012 views
  • 7 likes
  • 6 in conversation