Does anyone else make extensive use of pre-assigned libraries in the Metadata? In particular, is there any reason for the Display Libname right-click selection in SAS MC to not work when all the values are in the Metadata server? Clicking through to the pre-assignment check box in Advanced Options seems so clunky.
We use pre-assignemnt in 2 modes:
- In EG4 so users can submit code with meta assigned librefs without assigning them manually in the Server List.
- To avoid importing all metadata from DBMS when it changes frequently. Users can still access all their tables but I guess SAS/Access determines the properties dynamically.
Assigning libs using autoexec.sas or similar is a relativly obscure requirement. Any other considerations ?
Andrew, once you set a library as pre-assigned, you can not display the libname statement, nor can you import additional tables (cause and effect here). This is done primarily for security reasons: another reason for pre-assigning is that you don't want to expose the details of the libname statement. Because of these restrictions, the "clunky" UI could be positioned as making sure you really want to pre-assign by making you work a little more to do it.
Actually, I agree with you that the UI is a bit clunky, and we are looking at revamping the interface. Not sure when that will happen though.
Why do you think that using an autoexec is an obscure requirement?
Assigning default libraries in autoexec.sas is for relatively advanced PC/SAS users unless something has been set up by an administrator. Often, the SAS statements are specific to the local workstation and do not always translate to a Workspace session on the server e.g drive letters, email defaults, graphics settings. On a managed Windows server, users will not have access to the default location of C:\Documents and Settings\%USERNAME% so the path needs to be defined in one of the sasv9.cfg files.
Once all that is done, any librefs assigned using -autoexec will show up in an EG4 session regardless of the Metadata server so what is the point of pre-assignment in that situation?
Regarding Display Libname, I don't see the security issue. The same permission that allows the pre-assignment toggle to be flipped should control whether the libname is displayed. All the values needed are in the Metadata.
I have tried to construct query XML but it is too complicated when servers and schemas are involved. Is there any chance that the Java logic used in SASMC to create the same XML will ever be available?
Sorry for all the detail but my point is that it is not straightforward.
You are correct that assigning libraries via an autoexec for the backend server does not support end-user specific library assignments, if there are different paths that have to be taken into consideration. The current implementation of libraries in metadata are typically for shared data sources.
If it is imperative that different libraries are assigned to different sets of users, there may be a way to configure the metadata so that different users have access to different servers (or server contexts) that have different libraries assigned to them. I can't really go into more detail yet, as I'm still thinking through possible solutions to this dilemma. Once I have things worked out, I will share it with the community.
Can you share why you would like to get the XML for a library definition?