Review your metadata profiles using SAS Enterprise Guide automation

58

We call it the "metadata profile", but really it's like a telephone number that connects you to your SAS environment. Just as a telephone number has component parts (country code, area code, exchange), the metadata profile contains information that allow you to "dial in" to your SAS servers. This information includes:

  • a host name (node name or IP address of your SAS metadata server)
  • a port number (the TCP/IP port that the SAS metadata server uses to accept connections)
  • your credentials (the user ID and password that identify you when you connect)

All of this is captured under a friendly name, which you assign when you define the profile.  This is similar to the way that you would file a colleague's information in your Rolodex (still have that?) or contacts list.

When you're connected to a SAS environment in SAS Enterprise Guide, you'll see some of that profile information reflected in the status bar:

To activate a different profile or to define a new one, you can click on the Connections link in the status bar. This invokes the Connections window, showing all of your available profiles and their details.

The profile name is important, because you can make use of this name as a shortcut (similar to "speed dial") to direct SAS Enterprise Guide to a particular metadata environment automatically.  To learn more, read about how to use SAS Enterprise Guide with different SAS environments.

You can also use the profile name in SAS Enterprise Guide automation scripts, as shown in this example about running SAS programs in batch.

My objective in this blog post (and I'm taking a while to get to it) is to show how to use an automation script to list the available profiles that you have defined for your installation of SAS Enterprise Guide.  In this VBScript program, I use the Application.Profiles collection to obtain the details of each defined profile.  To set an active profile in script, use the Application.SetActiveProfile() method.  Note that if you want to run in "no profile" mode (not connected to metadata, simply using your local SAS installation), you specify "Null Provider" as the profile name.  (Aside: "Null Provider" would make a great name for a rock band, or maybe for a blog.)

Here's the VBScript program:

' force declaration of variables in VB Script
Option Explicit
Dim Application
' Create a new SAS Enterprise Guide automation session
Set Application = WScript.CreateObject("SASEGObjectModel.Application.4.3")
WScript.Echo Application.Name & ", Version: " & Application.Version
 
' Discover the available profiles that are defined for the current user
Dim i 
Dim oShell
Set oShell = CreateObject( "WScript.Shell" )
WScript.Echo "Metadata profiles available for " _
   & oShell.ExpandEnvironmentStrings("%UserName%")
WScript.Echo "----------------------------------------"
For i = 0 to Application.Profiles.Count-1
  WScript.Echo "Profile available: " _
    & Application.Profiles.Item(i).Name _
    & ", Host: " & Application.Profiles.Item(i).HostName _
    & ", Port: " & Application.Profiles.Item(i).Port
Next
Application.Quit

And here's an example of the output:

C:\Examples>cscript ShowProfiles.vbs
Microsoft (R) Windows Script Host Version 5.8
Copyright (C) Microsoft Corporation. All rights reserved.

Enterprise Guide, Version: 4.3.0.0
Metadata profiles available for sascrh
----------------------------------------
Profile available: Null Provider, Host: , Port:
Profile available: t2817, Host: t2817, Port: 8562
Profile available: uitsrv02, Host: uitsrv02.na.sas.com, Port: 8561
Profile available: uitsrv04, Host: uitsrv04.na.sas.com, Port: 8561

 

Share

About Author

Chris Hemedinger

Director, SAS User Engagement

+Chris Hemedinger is the Director of SAS User Engagement, which includes our SAS Communities and SAS User Groups. Since 1993, Chris has worked for SAS as an author, a software developer, an R&D manager and a consultant. Inexplicably, Chris is still coasting on the limited fame he earned as an author of SAS For Dummies

58 Comments

  1. A good modification to EG is to display the connected profile name somewhere in the status bar rather than the server name as a number of users don't know what server name is what etc.

  2. I have recently started to read your blog and I find useful topics.
    I want to make you a SAS/EG performance question:

    I have started to work with SAS/EG a few ago, I have worked a lot with SAS/BASE, but not SAS/EG.
    I have a doubt about SAS/EG. I know the main features of the tool, but I don’t know how it works with high volume of data and a lot of number of projects.

    I am starting a project with SAS/EG 4.3. We have to migrate JCL-Cobol process to SAS/EG. The process are typical process of reading files, sorting data, merging data, filtering data, aggregating data…, typical ETL steps. The process are typical process yo can do with SAS/EG.
    The problem is the volume. The volume of process and the volume of data used in the process.

    We have to migrate 500 processes. There are process that move files of 100 Gb.

    If I make 500 .egp projects in guide, ¿can we have them in a unique metadata or server?, ¿do I have to share out between several servers/metadata?. ¿How many projects can manage a metadata with good performance?.

    If you have to work with 100Gb files, would you use SAS/BASE or SAS/EG. I know, that I can modify code in my SAS/BASE programs to have a better performance, shorter processing times (objects like indexes, data in memory, etc..), but in SAS/EG I think I can modify less things….am I wrong?

    Other question:
    I will make the project in a windows server but I want to deploy it in a Unix server, the process will be scheduled in a Unix server and will be called from a .sh Unix shell script. Is it possible?, I think so…., but I prefer to make the question.
    As you can see my english is not profiency. I hope my questions are clear…
    Any advice will be greatly appreciated.
    Thanks in advance

    • Chris Hemedinger
      Chris Hemedinger on

      Juan: hola y mucho gusto.

      Your questions are good and valid. I cannot provide a specific recommendation for your scenario, but I hope to provide a little bit of information to help.

      EG does not read all data into the client session, so the fact that you are using EG to access large data should not be a problem. EG accesses the column metadata (variable names, types, and formats) and only the amount of records needed to display a screen's worth of data. (However, very wide data with thousands of columns can be slower, so beware of that.)

      It's true that you have less control over the process when you use EG's tasks to represent your work. EG generates syntax that is designed to work well with databases or SAS data sets, but for the best optimization you might still want to maintain the work in SAS programs. If you have SAS programming expertise, this will probably be how you are most productive.

      You can still drive those programs within EG projects. Use EG to organize the programs into logical flows, so it's easy to understand how the process fits together. You can maintain the programs in files on your Unix OS, as long as EG can connect to a SAS session on UNIX.

      This allows you to use EG for editing and testing your programs, but use your UNIX OS for scheduling via cron or whatever your preference is. You can also use EG automation for scheduling, but that must be driven via a Windows process, as EG is a Windows-based application.

  3. Hi Chris, thank you very much for your help. As you can see you have followers in Spain…
    I have more questions...

    Deployment in Unix:
    You design a .egp project in SAS/EG environment -> generate SAS code -> transfer the .sas to the Unix server -> run this .sas from a .sh shell script. (scheduled ).
    Is this the best way to operate if you have to execute in Unix?
    If I have understood you well, you can only scheduled process from the SAS/EG environment in Windows, am I wrong??

    Metadata management:
    Have you worked with a large amount of .egp projects in the same metadata/server?.
    We are going to build a large amount of projects.., at least 500..., and can be 20 users al the same time accesing...
    what do you recomend??.

    Your help is greatly appreciated.

    Have a nice weekend!!

    data.have;
    set nice.weekend;
    run;

    • Chris Hemedinger
      Chris Hemedinger on

      Juan,

      Yes, if you want a UNIX based scheduling process, then you will have to either:
      - maintain the SAS programs in the UNIX file system (but you can still use EG to develop and test), or
      - have the SAS programs in EG projects, and extract the programs before placing them in a production scheduled job on UNIX.

      As far as maintaining hundreds of EG projects - yes, that's possible. You can use either SAS metadata folders or UNIX file system folders. SAS metadata folders provide a logical folder structure and metadata permissions, BUT they do not provide an easy way to access the project files outside of SAS tools. UNIX file system folders are flexible in that regard, and you can rely on UNIX permissions to help manage access. And if you need to move the EGP files or reorganize, you can do so easily. So, given the little I know about your scenario, I think you would be happier if you kept the EGP files in the file system and not in metadata.

      Simultaneous access to the system by multiple users is no problem, but only one user can have a project file open for EDIT at a time. Multiple users cannot *change and save* a project file simultaneously, but multiple users may *run* the same project file.

      Enjoy your weekend!

      • Hi Chris,

        I have another question:

        Can I have the SAS/EG metadata in a Unix server??

        I would like to work from win clients that connect to a SAS Server in Unix, that SAS Server content the metadata (projects definitions, libraries, etc..).

        Thanks in advance

        • Chris Hemedinger
          Chris Hemedinger on

          Juan,

          Yes, SAS Enterprise Guide can connect to SAS metadata servers on UNIX, Windows, and z/OS (mainframe). And SAS workspace servers can be on the same. So the only tier where you must use Windows is on the desktop where your end users run SAS Enterprise Guide.

  4. Thank you very much for your help Chris.

    More questions....

    We have some JCL jobs in maniframe that we want to migrate to SAS/EG process.

    That mainframe job has about 20 JCL steps by average. This steps are read files, data sorts, data filtera, merge of files, agregations process,and some calls to Cobol programs with no-complex business logic.

    Thi jobs move files of 100Gb. aprox and are scheduled in a Control-M. The performance is good.

    The idea si create a .egp SAS/EG project with all that steps. Ths simple steps like sorts, reads, merges we are going to make with SAS/EG components and the Cobol programs will be translated to SAS/BASE.

    We will generate the SAS/BASE code of the .egp projects, move tha .sas file to Unix and call it by a .sh shell script or schedule in Unix Control-M. The Unix server will be a good machine, with necessaty resources.

    My doubts are ¿is SAS/EG a suitable tool to replace maninframe JOBS?, ¿its has any limitationes with his components?. For example, the read component of SAS/EG has few optiones compared with an input read step os SAS/DI.

    ¿Can we have performance problems?. ¿are Unix systems and SAS process as solid and robust like mainframe environment process?

    Any advice will be greatly aprecciatted.

    Thanks in advance. Chris..

    • Chris Hemedinger
      Chris Hemedinger on

      Juan,

      I know that many SAS customers have done just what you are doing: migrated from mainframe COBOL-based jobs to SAS programs. That's a well-proven path.

      You can use EG to develop/test/run these SAS programs against your UNIX server. Other than the work of converting your programs, it should be a straightforward process.

      The area to be careful about is when you use point-and-click tasks in EG to replace some of the programs that you need, especially for work such as importing data. You *can* use EG to import text files, but the EG Import Data task brings some of that work into the client tier. Instead, to maintain a server-centric approach, you should use SAS programs to do that work.

      For answers on questions that are specific to your environment, I suggest that you work with SAS Technical Support or other SAS consultants from your local SAS office. I can provide only limited advice/guidelines in this blog forum, of course...

  5. Chris,

    We have an environment with 3 SAS Servers (Test, Dev & Prod). How do I register/set up these servers so EG can utilize these Base SAS 9.2 servers?

    Currently my EG session says: "No Metadata profile selected". How do you create profiles?

    • Chris Hemedinger
      Chris Hemedinger on

      Jim,

      A metadata profile allows you to connect EG to a SAS metadata server and SAS workspace server. These are made possible by setting up SAS Integration Technologies (which you might have on its own or as part of a larger solution, such as SAS BI Server).

      To create a new profile, click on the "No profile selected" link in the EG status bar. That brings up the Connections window. You then click Add, which brings you to Create Profile. You'll need the host name of the metadata server, the port that it's listening on, and user credentials to connect. If you have a true dev/test/prod environment, you'll have a different metadata server instance for each environment (though they can all be on the same host, with different ports).

  6. Hi Chris,

    Thank you very much for your help and answers...

    A new question for you:

    I know that SAS/EG has a job scheduler in windows, but I don't know if it's possible to schedule a job
    in Unix using SAS/EG, is that possible??

    Thanks

    • Chris Hemedinger
      Chris Hemedinger on

      Juan, no, there isn't a UI method in EG that can interface with a UNIX scheduler. You can schedule an EG project using the Windows scheduler, and that project can have content that *runs* on UNIX, but it still requires the Windows client in the mix.

  7. Hi

    tried running the code but got an error saying

    SAS.EG.SDS.Metadata.MetadataException: Request for login credentials canceled by user
    at SAS.EG.SDS.Metadata.OMSProvider.Connect()
    at SAS.EG.ProjectElements.MetadataHelper.ConnectToProvider()
    at SAS.EG.Scripting.Application..ctor(String_cmdLineProvider)

    Any ideas?

    • Chris Hemedinger
      Chris Hemedinger on

      That sounds familiar. Check to make sure that you have the latest hotfixes for EG (4.3 or 5.1), as I believe a similar issue was addressed after the initial software shipment.

  8. Hi Chris,
    This may be a Silly Question .Can a user (once set up in the Metadata Repository via SMC) connect to only the Metadata Server via SAS EG? In other words if he does not have access to SAS Application Server administered by the Metadata server, can he just connect to the Metadata server via SAS EG. I understand that in doing so he cannot run any SAS Programs as the SAS App Server is not available.But is this possible at all via SAS EG? One of my colleague tried to login to SAS EG to metadata server even though he did not have access to the SAS Application server managed by the Metadata server and he was unable to do this. Why is this so?

    • Chris Hemedinger
      Chris Hemedinger on

      Prashant, not a silly question at all!

      You should be able to use EG to connect to a metadata server, even if you don't have an available SAS Workspace (application) server. You won't be able to open data or run programs, but you can view the content of SAS Folders.

  9. Hi Chris,
    Thanks for your answer to my question above. Now my only question is if SAS EG can connect to only the Metadata Server if needed, then how is this achieved?Basically when I launch the SAS EG application on my Windows machine at my Work , it first launches the Metadata Profile window called "Credentials Required" in which i enter my Userid and Password.And then it connects to the Metadata Repository ( say for eg TAASASF1) and at the same time it also connects me to the SAS Workspace (Application server) with the same name ie TAASASF1. But if in the Metadata Profile Window i enter the userid and Password of a person who has access to ONLY the Metadata Server (TAASASF1) but not the SAS Workspace server (TAASASF1) , then it does not allow him to login into the metadata Server. In this case the Metadata Profile window keeps prompting for the Userid and password again and again. So what is going on here? Is there any tweaking which is required for this person to login to just the Metadata Server (TAASASF1) or is it that my SAS Admin has setup the Metadata Profile in a way that does not permit login to just the Metadata Server (TAASASF1) ? Hope i am making sense.

    • Also Chris, the reason i say that this particular user has access to the Metadata Server (TAASASF1) is becuase he can access both the SAS Information Delivery Portal and SAS Web Report Studio associated with the Medata Server(TAASASF1) and he can run Reports registered with this Metadata Server. As such i am assuming he is defined as a User in the Metadata Repository.But this same user cannot connect to this Metadata Server via SAS EG. Am i missing something here in terms of the concepts of Metadata Server and SAS Application Server?

      • Chris Hemedinger
        Chris Hemedinger on

        To be able to connect to the SAS Workspace Server from EG, you need the "Log on as a batch job" privilege (assuming a Windows server) -- that is, your user login must be associated with a machine account that can connect. That requirement is not the same for ID Portal and SAS Web Report Studio users.

        However, I don't know why EG is making a connection to the Workspace server automatically. It should connect only to the Metadata server unless you try to open a data set, run a task, or run a program. You might need to work with SAS Technical Support to resolve this question. They might ask you to supply some logging information that the metadata server and object spawner will produce.

  10. Thanks for the SAS dummy blog...I have a problem in using my local profile. Whenever I try to connect to local it give me error saying that A connection could not be made to the SAS Metadata Server. Connection failed Could not establish a connection to the SAS server on the requested machine. Verify that the SAS server has been started with the -objectserver option or that the SAS spawner has been started. Verify that the port Combridge is attempting to connect to is the same as the port SAS (or the spawner) is listening on.

    I did also try to connect No profile Mode but I can't make any connection. Can you please help me with this??I am kinda really frustrated now. What is the requirement of program to run local profile and no profile mode??? I have Enterprise guide 5.1 and expired in july 2013. Thank you very much.

    • Chris Hemedinger
      Chris Hemedinger on

      Sandra, in order to run in "No Profile" mode you must have SAS installed on your local PC -- on the same machine with SAS Enterprise Guide. If you check Help->About SAS Enterprise Guide and click Configuration Details, you'll see whether SAS Enterprise Guide has detected a local SAS installation. If you have SAS installed on this machine but it's not showing up, you might need to run "sas /regserver" as described in this SAS Note. If the problem continues, I suggest that you contact SAS Technical Support.

  11. I'm running in no profile m on my loacl pC suing EGuide 5.1 and SAS 9.3. I trying to create a stored process but I get this error: "SDS Failed to provide the user context. Active OMSProvider is required". Any ideas?

    • Chris Hemedinger
      Chris Hemedinger on

      Tebogo,

      You can create stored processes only if you are connected to a SAS Metadata environment -- "No Profile" mode won't work for that. If you have just local SAS and no SAS Metadata Server, you won't be able to use SAS Stored Processes.

  12. Hi Chris, thanks for the blog article.
    I have a question similar to Sandra's one. I get the same error message also I checked for the installed SAS via the way you suggested (check Help->About SAS Enterprise Guide and click Configuration Details).

    Problem report created: Monday, February 03, 2014 3:23:06 PM UTC

    Error
    An unexpected error has occurred while accessing metadata
    A connection could not be made to the SAS Metadata Server but is required for the current operation. Please see your administrator.
    
    Connection failed
    Could not establish a connection to the SAS server on the requested machine.  Verify that the SAS server has been started with the -objectserver option or that the SAS spawner has been started.  Verify that the port Combridge is attempting to connect to is the same as the port SAS (or the spawner) is listening on.
    
    --- SAS Software ---
      SAS Enterprise Guide version: 5.100.0.12019
      SAS System version: 9302.0.20524.8057
      SAS System Command: c:\progra~1\sashome\sasfou~1\9.3\sas.exe -config "c:\program files\sashome\sasfoundation\9.3\sasv9.cfg"  -objectserver -nologo -noterminal -noprngetlist
    
    

    It is there since I have a SAS System version along with SAS EG version.
    The problem that I cannot create a stored process because this option is inactive when I click on any SAS program in my project. Could you please help me with that?

    • Chris Hemedinger
      Chris Hemedinger on

      Igor,

      In order to create a stored process, you must connect to a SAS metadata environment. The SAS Metadata Server is a separate process that runs (usually) on a central server for multiple SAS users to connect to. You can read about this and more in the SAS 9.3 Intelligence Platform: Administration Guide.

      If you work in an environment where you have centralized SAS environment, your SAS administrator can tell you the host/port and credentials to use to connect to it. If you simply have a SAS install on your local PC along with SAS Enterprise Guide, you typically would not have a SAS Metadata Server. It's possible to set one up, but you still need SAS Integration Technologies (a separately licensed product from SAS) to create/run SAS Stored Processes.

  13. I have similar issues and tried many times. The problem has not been solved.

    after I installed SAS enterprise 4.3, " A local SAS server was not found, and no metadata profile is being used. Without a SAS server you cannot open data or run SAS programs. Do you want to create or modify your profile information?"

    I click "Yes", a default with gray "set Active". I don't know how to set up from here?

    I tried to add few profiles, they are not working.
    for example, I added a profile and click "set Active", a popup error message shows " A connection could not be made to the SAS Metadata Server but is required for the current operation. Please see your administrator".
    what can I do next? please help.

    • Chris Hemedinger
      Chris Hemedinger on

      Grace, to use EG you either need a local SAS install (sounds like you don't have one), or access to an administered SAS environment. A SAS administrator -- the person/group who supports your SAS environment -- would need to provide you with the details that you need for your SAS profile.

      Are you a student who needs to learn SAS? You might look at the SAS University Edition, which is free and includes a SAS environment and the SAS Studio application for end users.

  14. Hi Chris,

    I have EG connected with metadata server with 2 grid nodes. I want to send two individual subtasks(2 PROC sort programs) to individual grid nodes(Grid node 1 and Grid node 2) and merge those subtasks in any one of the grid node with manual program with conditionally after completeion of two subtasks. So, in this scenarion how can i write the program? How to find the grid nodes and represent in the program with maually/conditionally?
    Currently when i analyze the normal SAS Program with Analyze the Program with Grid Computing , it is generate the code with session wise not like Grid node wise?
    Please clarify. Thanks

    • Chris Hemedinger
      Chris Hemedinger on

      The "Analyze for Grid Computing" feature should recognize the parts of your program that can run in parallel, and then trigger those parts in separate SCAPROC macros (that wrap the rsubmit sections for running the different program tasks). You can see more about this approach in the Grid Computing in SAS documentation.

  15. Hi, Chris.
    It's an enlightening blog.

    I have a silly question.
    Currently, I'm using EG 6.1 to connect to SAS Metadata 9.4.
    And, I constantly receives a dialog "Credentials Required" to input username and password. when I try to expand "SASApp".
    Do you have any idea about it?

    Many thanks in advance.

    BR./Edward

    • Chris Hemedinger
      Chris Hemedinger on

      Edward,

      If the credentials (user/password) you use for SAS metadata are different than those you use for the SASApp server, then you could see a prompt for credentials. There are various methods to work around this: create an authdomain for the SASApp server and record your credentials in there, cache your credentials locally (if permitted). These methods rely on your SAS administrator to set policies and privileges that allow these techniques. I recommend that you check with your SAS admin (hope you know who that is!) to see what can be done.

      • Hi, Chris.
        Thank you so much for your knowledge.
        The issue has been kind of solved. :-)
        I have grant ReadMetadata to group PUBLIC (SASApp authentication),
        and configured internal account for connect to Metadata server (SASMeta authentication).

        Thanks again.

        BR./Edward

  16. José Bonilla on

    Hi Chris,

    I'm trying some sample code to get a feeling of how this works. I have Excel 2013 and Guide 5, 6, and 7.11 32-bit. I'm getting different outcomes running in two different remote SAS servers, as described below. I need to be able to run it on both, so any help or pointers are appreciated!

    My Hello World code is as follows. This was tested on a remote SAS Server that does not use LDAP to authenticate and apparently does not allow credentials to persist (and hence everytime someone tries to connect to it via EG, the username/password dialog pops up) and submitting via VBA throws the error pasted below.

    Running the exact same code pointing to another remote SAS server (whose profile name is not "Grid" but "SAS Risk" works perfectly. This server is configured to authenticate via LDAP and also allows credential persistence, so I guess that's the difference.

    I am wondering how to pass connection info (userid/password) directly via the VBA code (instead of relying in the Profile) so I am able to run the code successfully.

    Also, when I get this to work, does this require EG installed, or can it run on Excel + Add in for MSOffice?

    Thanks

    --- Code Option Explicit Public Application Public Project Public sasProgram Public log1 As String Sub Example2() Dim x x = Time() Set Application = CreateObject("SASEGObjectModel.Application.7.1") Application.PromptForCredentials = True ' Assign the server and profile - Here's where the error pops up Application.SetActiveProfile ("Grid") ' Create a new EG project Set Project = Application.New ' Create a new code of Code Collection Set sasProgram = Project.CodeCollection.Add ' Assign output options sasProgram.UseApplicationOptions = False sasProgram.GenListing = True sasProgram.GenSasReport = False ' Select the server sasProgram.Server = "SASApp" ' Get current XLS path (VBA is being run from Excel) Dim DatafileDir As String DatafileDir = ThisWorkbook.Path ' Set the Hello World code sasProgram.Text = "data test; set work._prodsavail; run;" ' Run the code sasProgram.Run ' Save log to file and display in msgbox sasProgram.Log.SaveAs "C:\Documents and Settings\C109033\Escritorio\script1.log" log1 = sasProgram.Log.Text MsgBox sasProgram.Log.Text ' Show elapsed time in msgbox x = Time() - x MsgBox x End Sub --- Error SAS.EG.Scripting.ScriptingException: Connection to XXX.XXX.XXX.XXX:8561 requires valid credentials (userid and password).

    • Chris Hemedinger
      Chris Hemedinger on

      José,

      You will need EG installed in order to run this script -- the object model is part of SAS Enterprise Guide. But you should be able to launch this script from within MS Office if you want; some customers do that. Also, if you have the SAS Add-In for Microsoft Office, note that there is a scripting model for that tool as well (it's different).

      The credential issue probably requires that you seed the credentials in a credentials.xml file. That's described in this SAS Note.

  17. Dear Chris:

    I've run the vbs script described here in this blog post (updating to EG 5.1). The results are as follows:
    Microsoft (R) Windows Script Host Version 5.8
    Copyright (C) Microsoft Corporation. All rights reserved.

    Enterprise Guide, Version: 5.100.0.0
    Metadata profiles available for barboujb
    ----------------------------------------
    Profile available: Null Provider, Host: , Port:

    In other words, no profiles are found. I'm running on a Windows 7 machine with SAS EG 5.1 (32 bit). My SAS server is a remote AIX server.

    Is the reason that no profiles are found related to the fact that I'm running on Windows but my SAS server is a remote AIX server?

    The main reason I'm trying to obtain profile information is so that I can automate SAS EG projects. Right now, I can't connect to the SAS server. I added code to the SAS EG generated vb script to set the profile -- app.SetActiveProfile("MyUserNameHere") -- but it still won't connect.

    Thank you for any hints you may be able to offer,

    Jim

        • Chris basically talked me through the fix on communities.sas.com. If you're interested in the full details, by all means head over there. I'll put a summary here.

          SUMMARY
          This is a high level summary of what I did in order to get a vb script to run an EG project in batch mode in an environment with virtualized SAS EG (i.e. one where SAS EG isn't physically installed on the local hard drive but rather is invoked through some type of virtualization client such as Microsoft Application Virtualization Client):

          1. Generate a vb script
          2. Write a batch file that invokes the "bitness" correct version of CSscript.exe and executes the above generated vb script (this is not necessary if you use SAS EG to schedule a task in Windows but is necessary if you wish to test your vb script outside of the scheduler.)
          3. Download and install SASEGScripting.dll
          4. Download and install SAS Integration Technologies client
          5. Add one's profile to ConfigurationV51.xml
          6. Download and install SAS Providers for OLE DB

          The above changes have to be made on one's local machine, not on virtualized drives. You need to have Admin access on the machine.

          Note: I have only tried this with Microsoft Application Virtualization Client, but I think it would work with other virtualized forms of SAS EG such as Citrix.

          Thanks,

          Jim

  18. Chris,
    My Administrator set up a new SAS ID for me but on setting up the profile and then trying to update the Defaultuser password under Manage Login, I get the message:
    Call to updatemetadata failed
    [Error] The user does not have permission to perform this action.
    Unfortunately, my Administrator is doing this for the first time and not sure what to do.
    Please advise. Thanks.

  19. hi...I have installed sas 9.3 for training purpose while opening sas eg asking for meta deta profile. as this is training version than what would be the meta deta details...could you please help me

    • Chris Hemedinger
      Chris Hemedinger on

      If you have everything installed on the same machine (Windows), then you can simply choose "No Profile". SAS Enterprise Guide should find/use your local SAS.

  20. Tommaso Capelli on

    Hello Chris,
    I'm having a problem when scheduling a project(egp) that works both on server and local. What the project does is read some table on the server and, in some cases, run a .vbs script in local that runs other egp projects. I tried to schedule it but it wasn't working, so I edited the vbs script that SAS Guide creates for the main project to create a logfile with the error. It seems that the instance of SAS EG created by the script opens a dialog window and this shouldn't happen when it's run by the scheduler. So I tried to run the main vbs script by hand in cmd and the instance of SAS pops out a dialog window asking the connection credentials to local.
    I guess that the solution of my problem is in my connection profile, but sincerly I don't have any idea. Do you have any suggestions?
    Thank you in advance.

  21. RODRIGO DE OLIVEIRA SILVA on

    Bom dia,

    I'm trying to use the task scheduler from SAS Enterprise Guide 7.1, and it is returning error of 'Connection failed' as METADATA.

      • RODRIGO DE OLIVEIRA SILVA on

        I create an xml file, named "credentials.xml" and include it in 'C:\Program Files\SASHome\SASEnterpriseGuide\7.1' ??

        --------------------------------------------------------------------------------------------------------------------

        ----------------------------------------------------------------------------------------------------------------

    • Chris Hemedinger
      Chris Hemedinger on

      Are you using the correct CSCRIPT (32-bit for 32-bit EG, or 64-bit for 64-bit EG)?

Back to Top