Hi
I am new to SAS Viya.
I have a caslib called "X". I want to load a SQL table from another library into X with filters applied (meaning specific records from SQL only). I have this code below.
proc casutil;
load casdata="MSD" incaslib="LMENG" outcaslib="X" casout="MSDFiltered"
where="MasterClientName='XXX' and mode='Ocean' and YearQuarter='FY19Q3'";
promote;
run;
But I get an error saying the following . Any help to fix this is appreciated. Thank you.
"ERROR: Error occurred during Post Optimization.
I would start by tracing the query. See SAS Data Connector/SAS Data Connect Accelerator Logging
Hi
I read it and i think it is a syntax issue that I don't get it. I am not able to figure out what part of my Where clause is wrong. I was able to import the Full Table Called OceanRatingQueries. BUt what i really need is only when the Category says "terminal". Here is my code
proc casutil;
load casdata="OceanRatingQueries" incaslib="LMENG" outcaslib="STDOPT" casout="OceanRatingQueries";
WHERE="Category='Terminal'";
promote;
run;
You seem to have an extra semi-colon in the middle of your LOAD statement.
I have tried differen options like with and without semi colon.
When I remove the semi colon at the end of load statement i get a different error. Here is the details of it.
You had
ERROR: ERROR: [SAS][ODBC SQL Server Wire Protocol driver][Microsoft SQL Server]Incorrect syntax near the keyword 'Top'.
Now you have
Build your skills. Make connections. Enjoy creative freedom. Maybe change the world. Registration is now open through August 30th. Visit the SAS Hackathon homepage.
Register today!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.