BookmarkSubscribeRSS Feed
ThomasH
Calcite | Level 5
Dear forum,

I am facing an issue with DI Studio I cant find any documentation on.

There is 1 job which has a Lookup (missing table->abort) and a post-processing defined, which inserts a row into a "jobstatus" table containing the JOB_RC.

When running the job normally, it aborts when in case the lookup table is missing and executes the post-processing code.

When I run the job via an %include from another job, the lookup table is missing, the job aborts but does NOT run the post-processing code, thus not inserting the JOB_RC into my jobstatus table.

Why is the behaviour different?

Thanks a lot,
Thomas
2 REPLIES 2
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Possibly the ERRORABEND / NOERRORABEND condition may be the cause for different behavior? It would be best to share SAS log output with source code revealed for a proper diagnosis, after you have determined that the SAS behavior is different based on the two instances - check your PROC OPTIONS; settings for differences, possibly.

Scott Barry
SBBWorks, Inc.
Patrick
Opal | Level 21
Hi Thomas

"When I run the job via an %include from another job...' Does that mean you deploy the job and then in another job you're having a %include on the deployed job? If so: this wouldn't be the way you should do it in DI. Better use a loop control and embed the first job as inner object.

You have to look at the code/log to see what's going wrong. One reason could be that you use the %include statement within a macro and so all macro vars created by the pre-processing step of the included job outside of a macro are "suddenly" defined inside of a macro - they would become local instead of global (and that's one of many reasons why you should do things the DI way before writing user written code).

HTH
Patrick

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 1133 views
  • 0 likes
  • 3 in conversation