DATA Step, Macro, Functions and more

%EVAL function giving an error

Reply
N/A
Posts: 0

%EVAL function giving an error

Hi all!

I have a SAS file created
Thanks!
Frequent Contributor
Posts: 139

Re: %EVAL function giving an error

Posted in reply to deleted_user
Dear SASNewBee

Double check your macro code spefically

%macro trans( id, gid,sj, tdata);
data _temp_cs;
set &t_data;
run;

should the set &t_data be &tdata ?
Trusted Advisor
Posts: 2,116

Re: %EVAL function giving an error

Posted in reply to deleted_user
You need to turn on the options that Scott (SBB) recommends, so you (and we) can see what is going on. Without more detail of the log, it is a stab in the dark.

However, to stab in the dark, I'd guess that your connection to the database failed and thus &cnt is never created. The password warning is my key.
N/A
Posts: 0

Re: %EVAL function giving an error

Sorry but I dont see any posts from SBB. Which options do I need to turn on?
Super Contributor
Super Contributor
Posts: 3,174

Re: %EVAL function giving an error

Posted in reply to deleted_user
You really need to share *ALL* of your SAS code, not just sections. There is a macro you are invoking which is not revealed at all.

The OPTIONS setting mentioned - you may want to consider reviewing the DOC about diagnosing SAS programs is:

OPTIONS SOURCE SOURCE2 MACROGEN SYMBOLGEN MPRINT;

And there are times when you will need to add MLOGIC as well.

Scott Barry
SBBWorks, Inc.
Ask a Question
Discussion stats
  • 4 replies
  • 168 views
  • 0 likes
  • 4 in conversation