hi,
i am supposed to run a query such as
proc sql;
create table temp as select var1,var2
from have where var1>0
group by var2;quit;
and copy the results and paste into an excel sheet but when running my program file.sas which has this query i only get the log saying you created a table of 100 records and 2 variables but i dont get a file.lst file which would display the data so i can copy it and paste it.
it can not be a dataset. has to be data i copy from the listing. how do i achieve this? anyone pls?
"create able temp" creates a SAS data set.
you can get a several ways:
If you have SAS ACCESS licensed, you could directly export "temp" to Excel.
"create able temp" creates a SAS data set.
you can get a several ways:
If you have SAS ACCESS licensed, you could directly export "temp" to Excel.
Or use proc export to avoid the manual copy/paste operation.
Thank you!
Copy and pasting is a bad idea, it's too easy to make mistakes.
If you can't export to excel due to some license restriction - ie no SAS/Access look into the following macro.
http://www.sascommunity.org/wiki/A_Poor/Rich_SAS_Users_Proc_Export
Or export to a CSV, and then save as an Excel file, since you're doing a manual step anyways.
Thanks Reeza,
I did export it into an excel file but they did not want it that way. They have always been copying and pasting the listing. Dont know why.
the max ls(linesize) is 256 right?
I was trying to shrink the output a bit but i guess in SAS thats the maximum
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 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.
Ready to level-up your skills? Choose your own adventure.