BookmarkSubscribeRSS Feed
lethcons
Obsidian | Level 7

I have DI Studio job A. Within it it calls job B and then job C. Is there any way I can share work tables and reference them as input/output tables in my jobs? Currently all I can think of is to write them to permanent data sets in permanent libraries that are registered in metadata. For various reasons this is far from ideal.

Thanks.

2 REPLIES 2
Kurt_Bremser
Super User

Per definition, WORK is always "private" to a given SAS instance, and exists only while the instance is active. If you need program B to have the same WORK context as program A, you need to %include it in A.

From what I know about DI, each job will run in a separate BatchServer session, so you have to use permanent libraries to hand data over from one job to another.

lethcons
Obsidian | Level 7

Jobs B and C are nested within A so as far as I can see from the generated code they are all one SAS instance.

 

I think I've found a way to do it.

In job A create the work data set as usual.

In job B create a User Written Code node that has no code but has an output work data set. Manually give it the same name and variables as the work data set created in A. It will then work.

 

See the attached package to see for yourself. Run job A and check the Output window.

Please let me know if you have any better ideas.

 

Thanks.

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 480 views
  • 0 likes
  • 2 in conversation