I was going through couple of articles on how to connect to SAS from VB. I found two different methods to achieve the same.
Can anyone help me to understand what is the difference between connecting using SASWorkspaceManager and SASObjectManager.
Dim obWSMgr As New SASWorkspaceManager.WorkspaceManager
Dim obWS As SAS.Workspace
Dim errString As String
Set obWS = obWSMgr.Workspaces.CreateWorkspaceByServer("My workspace", VisibilityNone, Nothing, "", "", errString)
Debug.print obWS.Utilities.HostSystem.DNSName
ObWS.Close
Dim obObjectFactory As New SASObjectManager.ObjectFactory
Dim obSAS As SAS.Workspace
Set obSAS= obObjectFactory.CreateObjectByServer("", True, Nothing, "", "")
Debug.print obSAS.Utilities.HostSystem.DNSName
ObSAS.Close
If you are asking for concepts.....
There is a sas metadata server with a metadata base.
You can start a process from there. Appserver with underlying workspace servers are part of that.
You do not need a metadata server when you have a running object spawner that one will manage the appservers with underlying workspace servers.
As you not always using a server managed approach but also your desktop the classic sas usage is also offered as a local workspace service ugh workspace server.
Using the Object Manager gives you some more options than when you are using the Workspace Manager, particularly if you're connecting to a Metadata Server. If you're just using a Local Workspace session without a Metadata Server then to be honest there's probably not much difference - at the end of the day both will give you a SAS Workspace session.
You might find this link helpful SAS(R) 9.4 Integration Technologies: Windows Client Developer's Guide
Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!
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.