BookmarkSubscribeRSS Feed
DrewN8
Calcite | Level 5

Hello!

 

I'm new to SAS and excited to learn. Unfortunately, I've immediately run into an error with my data. I'm following along with SAS Institute's "SAS 9.4 Cert Prep: Part 01 SAS Programming Essentials":

(https://www.linkedin.com/learning-login/share?account=57888345&forceAccount=false&redirect=https%3A%...)

 

At 3:13 in the video linked above, the instructor runs a highlighted chunk of code to import an excel workbook into SAS. She had no trouble running the code, but I did. Attached below are images of the instructor's code, my code, and my log. I'm using the online SAS studio and followed the setup instructions prior to starting the course. Right away I noticed I had a line commented out (her line 23, my line 24), so I tried running with that line included as well and got errors again. 

 

I did not edit any of this code, I simply highlighted and ran the same section as she did. I'm sure this is a simple issue, but I don't know how to resolve it. Any help would be greatly appreciated. Thanks in advance!

 

Instructor's CodeInstructor's CodeMy CodeMy CodeMy LogMy Log

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

10 REPLIES 10
Kathryn_SAS
SAS Employee

In Server Files and Folders, right-click on the data folder and select Copy path or Insert as path and place that in the datafile= before storm.xlsx.

Try that rather than using a macro variable. If that works and you want to use a macro variable, then you can replace that path for the %let path= assignment.

DrewN8
Calcite | Level 5

Hi Kathryn,

 

Thank you for your response! While there is no direct "Copy path" or "Insert as path" option on my screen after right clicking the data folder, I found a path by selecting the "Properties" option:

 

"/home/u64390443/EPG194/data/data"

 

I pasted after 'datafile="' and before '/storm.xlsx"' then tried running but got the same error.

Kathryn_SAS
SAS Employee

Please send a screenshot and current log.

Kathryn_SAS
SAS Employee

I think you may have an extra /data subdirectory. Can you try:

proc import datafile="/home/u64390443/EPG194/data/storm.xlsx"
 dbms=xlsx out=storm_damage replace;
sheet="Storm_Damage";
run;
DrewN8
Calcite | Level 5

This gave me the proper output but I still have a couple errors in the log. I'm not sure if this will affect anything later on. I wonder why there was an error with the macro variable to begin with. If this is the only change I need to make and everything else works fine in the course, then great but considering I'm only 3 minutes into the first video of many I doubt that'll be the case. Is it possible I did something wrong in the course setup/data retrieval? It all seemed pretty simple, so I don't know where I would've went wrong.

 

Screenshot 2025-11-12 121541.pngScreenshot 2025-11-12 121747.png

Tom
Super User Tom
Super User

You have the PATH macro variable set to the wrong value.  That is why the LIBNAME statement did not work.

 

Since your PROC IMPORT worked you need to set the PATH macro variable to the same value you used there.

 

Note that a path that starts s:  is not going to work on a UNIX machine  like the one you are using to run SAS.   If the path does not start with / then it will be interpreted as being RELATIVE to the current directory.   You need to use a fully qualified path like what you used in the PROC IMPORT step. 

Rachel_McLawhon
SAS Employee

Could you provide the link or document you used for course/data setup? I'd like to recreate the steps to ensure they're clear and accurate for the future. Thanks!

DrewN8
Calcite | Level 5

Good morning Rachel,

 

I started this course on LinkedIn Learning. The course is titled "SAS® 9.4 Cert Prep: Part 01 SAS Programming Essentials". I downloaded the zip included in the exercise files. If you're looking to recreate my steps exactly, you should download the files directly from LinkedIn. I can't attach all of the setup files, but I'll include a screenshot of the "README".

 

I think the SAS Studio through SAS OnDemand for Academics is great since I can work off a cloud, preventing potential issues from storing files locally or on my employer's cloud. 

 

I'm completely new to SAS and only have minimal experience using Python, SQL, JavaScript, so nothing here is intuitive for me. I encountered this issue 3 minutes into the first video, where the instructor is focused on setting up our data and building familiarity with SAS Studio. If the course is meant for beginners, it wouldn't make sense to expect participants to be able to edit or understand any code yet. LinkedIn says over 54,000 people have enrolled and I haven't found any other documentation related to this issue, so I'm well aware I could have botched my data setup. I just don't know how. The directions are simple and straightforward, and everything seemed to load to the cloud properly.

 

I apologize for the delayed response. I have limited time at work for this course. Does anyone have recommendations for beginner level SAS courses if this isn't where I should be starting?

Thank you all for your quick responses and willingness to help!

 

Screenshot 2025-11-17 102824.png

 

Rachel_McLawhon
SAS Employee

Thanks, @DrewN8, for this additional information!

 

I was able to recreate your issue and have passed on guidance to the content development team to ensure nobody else experiences this. Since this first demo includes a lot of code that participants aren’t expected to understand at this stage, most don’t run it alongside the instructor and, as a result, don’t experience the error. All the other programs and files you set up for the course should work as expected!

 

I'm glad that you're enjoying SAS On Demand for Academics and pursuing SAS Programming! This is definitely the right class for you since it sounds like you have an interest in programming. Fun fact: SAS can integrate seamlessly with open source languages you mentioned! 

 

If you run into any other problems or have questions as you're learning, let us know!

sas-innovate-2026-white.png



April 27 – 30 | Gaylord Texan | Grapevine, Texas

Registration is open

Walk in ready to learn. Walk out ready to deliver. This is the data and AI conference you can't afford to miss.
Register now and lock in 2025 pricing—just $495!

Register now

SAS Training: Just a Click Away

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

Browse our catalog!

Discussion stats
  • 10 replies
  • 711 views
  • 0 likes
  • 4 in conversation