BookmarkSubscribeRSS Feed
jhh197
Pyrite | Level 9

Hi ,

I have an excel file which looks like below A1 and it has data from A TO G  and i want to create a sas dataset A2  which has A TO C coloumns only and also from row3  Can anyone pls help

 

 

A1 (EXCEL)

sales01sales01sales01sales04sales05sales06sales07
PSCVCC    
IDitem1item266    
0236456    
0236456    
1321333    
2254222    

 

 

A2 (SAS DATASET)

IDitem1item266
0236456
0236456
1321333
2254222
2 REPLIES 2
Reeza
Super User

What version of SAS are you using? Have you tried specifying the Range option? You will need to know the exact range ahead of time though. 

SASKiwi
PROC Star

If your column headings don't change you could import exactly the columns you require using the LIBNAME statement with the EXCEL engine (assuming you have SAS/ACCESS to PC Files) and using a DATA step or SQL.

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
  • 2 replies
  • 614 views
  • 0 likes
  • 3 in conversation