Write and run SAS programs in your web browser

Macros not resolving when executing campaigns in SAS CIS

Reply
Occasional Contributor
Posts: 11

Macros not resolving when executing campaigns in SAS CIS

Hi All,

 

We are executing a SAS DI job in batch mode and the job is completed successfully. But when we execute the sas job through SAS CIS by executing a campaign the jobs log shows error like "Macro not resolved". The macro paths are kept in autoexec file. This is happening with all the macros and macro variables .

 

Kindly help us on this.

 

Thanks in Advance

Esteemed Advisor
Posts: 5,954

Re: Macros not resolving when executing campaigns in SAS CIS

Look at the logs, especially the part where the autoxec is executed. It might be that the system user that runs CIS does not have the necessary permissions to read the includes.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 11

Re: Macros not resolving when executing campaigns in SAS CIS

Hi,

 

We are getting below error.

 

NOTE: Autocall member, WRITEHEADER, has not been compiled by the macro processor. It might contain a macro syntax error or not define a macro with the same name as the member. To autocall
this member again, set OPTION MRECALL.
MPRINT(FLUSSI_OUTPUT): ();
345 %writeheader();
_
180

ERROR 180-322: Statement is not valid or it is used out of proper order.

Esteemed Advisor
Posts: 5,954

Re: Macros not resolving when executing campaigns in SAS CIS

Are you using the autocall facility also in DI batch jobs, or are you simply including the files there?

And is the file where the macro %writeheader is defined named writeheader.sas?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 11

Re: Macros not resolving when executing campaigns in SAS CIS

Yes we are using autocall only.. Macro path is included in autoexec. The name of macro is same as the .sas name. Also, the same issue is coming for all the macros and macro variables used in the job.

Esteemed Advisor
Posts: 5,954

Re: Macros not resolving when executing campaigns in SAS CIS

On which system platform are you running SAS (the server part)?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 11

Re: Macros not resolving when executing campaigns in SAS CIS

We are using UNIX platform.

Esteemed Advisor
Posts: 5,954

Re: Macros not resolving when executing campaigns in SAS CIS

Could you post the code for the %writeheader macro here, or does it contain sensitive information?

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Occasional Contributor
Posts: 11

Re: Macros not resolving when executing campaigns in SAS CIS

Yes it does have sensitive information Smiley Sad

Esteemed Advisor
Posts: 5,954

Re: Macros not resolving when executing campaigns in SAS CIS

There's surprisingly little in the SAS knowledge base to be found for this NOTE, and that is related to z/OS.

So the only thing that's left from my POV is some difference between the two environments (user permissions, option settings) that makes the macro syntactically or semantically wrong in the CIS.

 

In any case, I'd put the issue to SAS technical support. With them, it's easier to reveal the code.

---------------------------------------------------------------------------------------------
Maxims of Maximally Efficient SAS Programmers
Post a Question
Discussion Stats
  • 9 replies
  • 158 views
  • 0 likes
  • 2 in conversation