BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
gregor1
Quartz | Level 8

I have the following code to load JASON output in to my SAS project:

filename out TEMP;

filename cacm TEMP;

proc http

url='https://XYZ.STU.com/api/now/table/...policy.contract_state_code&sysparm'

method="GET"

out=out

headerout=cacm

auth_basic webusername="cacm_rest_user" webpassword="XXXXXXXXXXXXXXXXXXXXX";

run;

libname CACM json "%sysfunc(pathname(out))" ;

proc copy inlib=cacm outlib=WORK;

run;

libname CACM JSON "%sysfunc(pathname(out))" fileref=data;

data out;

set CACM.alldata;

run;

data _null_;

rc = jsonpp("data","log");

run;

 

This works fine and gives me an "OUT" table, a "RESULT" table and an "ALLDATA" table.  However, it stops my process flow there unless I manually run the branch.  I want to continue the process flow, which clean up the data and joins with other tables in the SAS project.  I think I am missing a step to be able to use the output in these three tables as an input to other part of my SAS project.  I do get the following error when I run the above code:

ERROR: Physical file does not exist, /config/sas94/Lev1/SASApp/data.

Any ideas?

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

Create a permanent library.

Instead of copying to WORK copy to that library.

Clean up that permanent library as needed in the future.

This will require you to reference the data in that permanent library using the library name and not the single level name.

View solution in original post

1 REPLY 1
ballardw
Super User

Create a permanent library.

Instead of copying to WORK copy to that library.

Clean up that permanent library as needed in the future.

This will require you to reference the data in that permanent library using the library name and not the single level name.

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 1 reply
  • 728 views
  • 1 like
  • 2 in conversation