BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
data_null__
Jade | Level 19

You don't need sashelp.vcolumn or dictionary.columns or PROC CONTENTS for this task.  You can use VNEXT to put the name row and in the same data step put the observations.

data _null_
  
set SASHELP.class; 
  
file log dlm='|' dsd
  
if _n_ eq 1 then link names; 
  
put (_all_)(:); 
  
return
names: 
  
length _name_ $32
  
do while(1); 
     
call vnext(_name_); 
     
if upcase(_name_) eq '_NAME_' then leave; 
     
put _name_ : @; 
     
end
  
put
  
return
  
run
mediaeval
Calcite | Level 5

Hi data _null_, how do you format your code when posting to the forum?

RW9
Diamond | Level 26 RW9
Diamond | Level 26

Is the code written like that in your SAS window, if so then format there and then copy to notepad and then to this window, also you can use the advanced editor top right of the edit window.

As for your slowdowns, could be any number of things.  How is SAS installed, locally, network, virtual, what speeds are the networks running at, how much ram on the server etc.  I would run through the executing process with your SAS/Network people to see why you are getting such speeds, its probably something simple, for instance we were getting terrible speeds sometime back, there was a syncronisation program running which was interfering with read/write on files.

data_null__
Jade | Level 19

From SAS EG program editor window.  Right click on the program and choose "Copy HTML source to clipboard"

In this forum's reply editor window click HTML (toggle HTML mode).  Then paste and click HTML to toggle back.

jakarman
Barite | Level 11

@mediaeval for the performance try to understand what you are causing in the system. See my previous post(s).

---->-- ja karman --<-----
mediaeval
Calcite | Level 5

Thanks everyone for taking the time to answer. In the end I used Quentin's solution and runtimes have reduced from 10 minutes or so to just under 3 minutes.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 20 replies
  • 3380 views
  • 8 likes
  • 7 in conversation