I am trying to import this data set into SAS and keep getting this message. I copy and pasted the data into the editor and highlighted it and clicked the little running man up top.
City State Price
Baltimore MD 10.95
Brooklyn NY 12.99
Buffalo NY 11.50
Harlem NY 12.50
Newark NJ 11.50
Rochester NY 10.95
Stamford CT 11.50
Syracuse NY 10.95
Troy NY 11.50
Hi @harveysarah0 Welcome to SAS communities. Where is your code?
data have;
input City :$15. State :$2. Price;
cards;
Baltimore MD 10.95
Brooklyn NY 12.99
Buffalo NY 11.50
Harlem NY 12.50
Newark NJ 11.50
Rochester NY 10.95
Stamford CT 11.50
Syracuse NY 10.95
Troy NY 11.50
;
proc print noobs;run;
Hi there,
Again I am very new to using SAS and don't know a whole lot about the program. To make it a data set do I have to use the code you just provided?
Ah Okay, I was scratching my head to understand your Error. Oh well, how embarrassing for me. Yes, you can use the code I provided to read in your raw data values instream to create a dataset named HAVE with those values.
To print i.e to view the dataset, you can use the proc print code that follows the creation code.
Thanks so much again. Why do the city and state have those $ values next to them?
You need some training/learning help. Calling/Requesting @Reeza to help new learners to provide some guidance/directions just like what I received a few years ago.
Also @AnnaBrown has a list of youtube videos tutorials. Let's see if they chime in.
Nonetheless, If you have O'Reily media Safari library membership, you can learn from the very basic to any imagination.
All the Best!
Thanks for looping me in here, @novinosrin!
@harveysarah0, I don't believe there's a specific YouTube video that will solve your problem (though it's possible How to import CSV files into SAS could help), but do subscribe to the SAS Users YouTube channel where SAS tips and tricks are posted each Monday. In particular, the SAS How to Tutorial playlist may interest you for task-oriented instruction that you can learn from.
Best,
Anna
What code did you use that produced the error message "Error 188-322 Statement is not valid or it is not used in proper order."?
I did not use any code but instead just copy and pasted the data given by my professor. How do I make this a data set? Thanks.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.
Ready to level-up your skills? Choose your own adventure.