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

Please post any example code for impoting XLSX type of file using Proc import syntax.

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

What version of SAS do you have?

 

You may not have a license to import/export SAS files either, it requires SAS ACCESS to PCFILES I believe.

 

Try running the following to see if it lists SAS Access in the listing. If you post the output to here, make sure to remove your Site number.

proc setinit; run;

proc product_status; run;

 

 

View solution in original post

5 REPLIES 5
Reeza
Super User
proc import out=want datafile='/folders/myfolders/myfile.xlsx' dbms=xlsx replace; run;
Bhargav_Movva
Fluorite | Level 6

Thanks for your reply...

 

Code i submitted--->

proc import
datafile="E:\SAS\SAS_Total\practice programs\proc_import.xlsx"
out=importingxl dbms=xlsx replace;
run;

 

log---->

proc import
 datafile="E:\SAS\SAS_Total\practice programs\proc_import.xlsx"

out=importingxl dbms=xlsx replace;
ERROR: DBMS type XLSX not valid for import.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE IMPORT used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds

 

Can you please spot what's wrong

Reeza
Super User

What version of SAS do you have?

 

You may not have a license to import/export SAS files either, it requires SAS ACCESS to PCFILES I believe.

 

Try running the following to see if it lists SAS Access in the listing. If you post the output to here, make sure to remove your Site number.

proc setinit; run;

proc product_status; run;

 

 

Bhargav_Movva
Fluorite | Level 6

Thanks!!!!

 

 

manish_1
Fluorite | Level 6

Hi,

I want to know that if i have data in excel file and i want to get only selected data out of it to make a dataset so can we use where statement in proc import. ?

if not then how can i import selected data out of excel file ?

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!

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.

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