BookmarkSubscribeRSS Feed
dishenpancholi
Calcite | Level 5

Hi Everyone, 

 

I am writing datasets from a SAS Base library to a CASLIB using the below code. 

 

proc datasets lib=dash; /* This is my SAS Base library */

copy out=cldast; /* This is my CASLIB */

run;

 

Now I want these tables to be available in SAS VA for which I believe I will have to promote the datasets in the CASLIB to a global scope. Is there a way to promote all the tables at once or do I need to promote each table one by one using the CASUTIL PROMOTE procedure. 

 

Thank you in advance for your help. 

Dishen

1 REPLY 1
DerylHollick
SAS Employee

I don't see a way to do this with proc datasets (nor proc copy) but it would be nice to have.  Maybe something like:

proc datasets lib=dash; 
copy out=cldast promote=yes; 
run;

You could suggest it:  https://communities.sas.com/t5/SASware-Ballot-Ideas/idb-p/sas_ideas

 

In the meantime, proc cas can be used to promote all the tables in a caslib:

proc cas;
  table.tableinfo result=tablesToPromote / caslib="cldast";
  do i = 1 to dim(tablesToPromote.TableInfo);
      tname = tablesToPromote.TableInfo[i,'Name'];
      table.promote / caslib="cldast" name=tname;
  end;
quit;

 

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

Register now!

How to Concatenate Values

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 1 reply
  • 846 views
  • 0 likes
  • 2 in conversation