Desktop productivity for business analysts and programmers

SAS Enterprise Guide library name (label) change - impact on EG scripts

Reply
Occasional Contributor
Posts: 6

SAS Enterprise Guide library name (label) change - impact on EG scripts

Dear all,

 

we are trying to switch over from a Sybase 15.1 data base to MS SQL server 2016. In SAS Management Console, we have named the libref 'sybsprod' (label: ATLAS) for Sybase and the libref 'live' (label: POCMSSQL) for MS SQL. The content of the two libraries are exactly the same (table names and columns).

 

In our SAS EG scripts (6.1 version, and SAS Base 9.3), the tables are pointing to the 'ATLAS' label and now have to change to the 'POCMSSQL' table. If we are only changing the libref's in SAS Base, that would be an easy exercise. However, in the EG scripts we only have the manual change of the table references to the new library. We have almost 100 scrpts all over the company.

 

Note: We have only one production instance, where we do develop and deploy live versions.

 

Do you know an easy solution to switch library labels of all the tables?

 

In addition, do you see any other impact on the switch process?

 

Thank you in advance and best regards.

Esteemed Advisor
Posts: 5,202

Re: SAS Enterprise Guide library name (label) change - impact on EG scripts

Not sure how, and what impact in your EG scripts the library label has. Can you elaborate and give some examples?

 

On power of SAS is that you can change the data source without changing your code. So my immediate thought would be to keep the same libref for the new database connection, and that would hopefully leave your code working without changes.

 

That said, EG is primarily an ad-hoc environment. If you wish to create production batch jobs within EG it is important to design the jobs accordingly. One principle is to use meta librefs whenever appropriate.

Data never sleeps
Respected Advisor
Posts: 3,069

Re: SAS Enterprise Guide library name (label) change - impact on EG scripts

If you had more than one Production instance I think you could duplicate your database sources (different names/labels but same LIBREFs) and have the Sybase sources assigning only on one instance and the SQL Server instances only on the other.

 

Setting up a new server instance would be helpful for testing also.

 

On the other hand the EG find/replace function can easily go through a program and automatically change all LIBREFs. 

Ask a Question
Discussion stats
  • 2 replies
  • 243 views
  • 0 likes
  • 3 in conversation