BookmarkSubscribeRSS Feed
MoreThanSAS
Calcite | Level 5

Hi all,

I have a program and need to use relative paths.  In this program's lifecycle it moves from a /dev folder to a /prod folder, so I can't use an absolute path.  This is very straightforward, so I can't understand why it's not working.

This is using SAS GRID, running SAS 9.4, executing through GSUB.

ODS RTF FILE="output.rtf";

PROC PRINT DATA=sashelp.class;

RUN;

ODS RTF CLOSE;

When I run this with GSUB I get an insufficient authorization error because it tries to write somewhere in /GRIDWORK.

Things I have tried

  1. -GRIDGETRESULTS : With the insufficient authorization, this option doesn't help.
  2. I then parsed out the path from &sysprocessname, and sent the output there (ODS RTF FILE="[parsed out path from &sysprocessname]./output.rtf).  Then I don't get the 'insufficient authorization' note, and the RTF ends up in the GRID Results folder, but it does not copy it back to the directory in which the program is saved.

The last thing I can imagine is to somehow get the path where the program is saved, get that into some macro variable and add it to the FILE statement.  This path doesn't seem to exist within SAS, though -GRIDGETRESULTS seems to know where to put the .log and .lst, so SAS must know it somewhere.  I guess the question is, can it pass the value to me somewhere?  Perhaps through SYSPARM?

Any help appreciated.

1 REPLY 1
Cynthia_sas
SAS Super FREQ

Hi:

  This really is more of a question for Tech Support. I don't have a grid image to test on, but Tech Support can find one or can direct your question to someone who can test on a grid image. Unless someone who is using GRID just happens to know the answer off the top of their head, it seems to me that Tech Support will be your best resource.

cynthia

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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.

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
  • 971 views
  • 0 likes
  • 2 in conversation