BookmarkSubscribeRSS Feed
Pavan_SAS
SAS Employee
1. What is an in-line macro?
2. How to swap 2 macro variables without creating 3rd macro variable?
3. Suggest a way to enlist tables that have a column containing string - ‘asset’?
9 REPLIES 9
ArtC
Rhodochrosite | Level 12
hmmmmm interesting questions.
> 1. What is an in-line macro?
Are you perhaps referring to either a statement style or command line macro?

> 2. How to swap 2 macro variables without creating 3rd
> macro variable?
I have never needed to do this is there a specific motivation? The use of a third temporary variable seems like a small cost.

> 3. Suggest a way to enlist tables that have a column
> containing string - ‘asset’?
Sorry I am not sure what you mean. Any data set with a variable with the name ASSET or any data set with any variable which contains a value of 'asset'. I am guessing the second and that you do not want to actually read the potential data sets.
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Is the OP asking the forum subscribers do their homework here?

Scott Barry
SBBWorks, Inc.
Pavan_SAS
SAS Employee
.
Pavan_SAS
SAS Employee
.
Pavan_SAS
SAS Employee
.
Pavan_SAS
SAS Employee
.
Pavan_SAS
SAS Employee
.
Patrick
Opal | Level 21
Pavan

Yes, this is a technical discussion forum - which expects users to first do their own bit of work and then ask questions when they've got stuck.

For example the following search terms in Google - SAS "in-line macro" - and the very first hit links already to a white paper explaining what an in-line macro is.

Thanks
Patrick
Cynthia_sas
SAS Super FREQ
Hi:
Generally, when people refer to "in-line" macros, they are referring to "session compiled" macro programs that are compiled and used within the same program. Usually, they reside in the WORK library, as described here, in the documentation (as opposed to autocall macro programs or Stored compiled macro programs):
http://support.sas.com/documentation/cdl/en/mcrolref/61885/HTML/default/viewer.htm#/documentation/cd...

And these 2 papers are very good resources for the beginner (in addition to the most excellent books written by Art Carpenter):
http://www2.sas.com/proceedings/sugi29/243-29.pdf
http://www2.sas.com/proceedings/sugi28/056-28.pdf

I'm not sure what you mean by #2 and #3 -- this is an instance where a concrete example or more explanation would be useful. Especially, what you mean by the phrase "enlist tables" in the sentence "Suggest a way to enlist tables that have a column containing string - ‘asset’" If you want to find tables that have a column which contains "asset" as part of a column name, then you will want to search for previous forum postings on the use of the SAS Dictionary tables or the SASHELP "V" tables.

And, if this is a homework assignment, then your best resource is your professor or teaching assistant for the class.

cynthia

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

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
  • 9 replies
  • 2079 views
  • 0 likes
  • 5 in conversation