BookmarkSubscribeRSS Feed
kimmygzc
Obsidian | Level 7

Struggling with SAS command line...

 

I've been using SAS EG for a while, and want to try batch work arrangement by windows CLI(for some permission level restriction I can't use scheduls in SAS EG...).

 

But I have to connect to metadata sever every time  I start EG, which I don't know how to finish in command line, I guess there should be some sas.exe parameters to set up the "bridge" connection with [remote server address, port, user name, password...]

 

Is there a handbook I may follow?

 

appreciate in advance for any rely.

3 REPLIES 3
gwootton
SAS Super FREQ
The SAS session that Enterprise Guide connects to is a Workspace Server. The Workspace Server establishes a connection to the Metatdata Server by way of the Lev1/metadataConfig.xml file that is called by the METAPROFILE in Lev1\SASApp\sasv9.cfg. This establishes a connection to the Metadata Server using the connection details in that XML file as the process owner or in the case of SAS Token Authentication using a one-time password for the user who requested the server from the Object Spawner.

To connect to Metadata from a SAS session started in batch you could use the Batch Server to start SAS (i.e. Lev1\SASApp\BatchServer\sasbatch.cmd) which would also load that metaprofile option, or in a SAS session started from <SASHome>\SASFoundation\9.4\sas, use the metadata connection options (e.g. metaprofile, or metaserver/metaport/metauser/metapass).

Connection Options
https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/lrmeta/n03ph3v01d4e7en1n0v7wm8o3yiu.htm
--
Greg Wootton | Principal Systems Technical Support Engineer
SASKiwi
PROC Star

SAS Management Console provides a point-and-click interface to schedule and run SAS batch programs - if you are creating EG projects then you need to export these to SAS programs first.

 

Is this a possibility for you? SMC needs to be installed on your PC like EG, but once it is you connect to a remote SAS server just like in EG. 

Sajid01
Meteorite | Level 14

Hello
If one wants to run SAS code in batch mode from command line, it is not  necessary to connect to the metadata server. However this is to be run a machine on which SAS is installed.

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 3 replies
  • 1264 views
  • 3 likes
  • 4 in conversation