Hi all,
I am trying to leverage some of the benefits of proc fedsql and cas, however I am facing some issues with the syntax in comparison, previously when i tried to filter rows using proc sql I just used a where clause, however when i do the same using proc fedsql, I get a error saying the column name exist for the filter value I am trying to apply:
WHERE VAR = "PROD";
It will return an error saying the column "PROD" does not exist or cannot be accessed, so I just want to understand the syntax difference that is more than likely causing this.
Weird ... because nothing is wrong with
WHERE VAR = "PROD";
Maybe you need to show us the full program.
Are you using SAS 9.4 or SAS Viya 3.5 or SAS Viya 4?
Are you using PROC FEDSQL on the CAS server (with CAS tables) or against an external database (like Oracle)?
Koen
Yes, for some reason it didn't like the double quotes, when I changed it to single quotes it seemed to run ok.
I have realised that whilst I get no error and I have now run into a different problem - it returns no rows where the clause has actually been met.
I realised the macro variable I was using as my condition for filtering wasn't resolving with either single or double quotes, so put %TSLIT around it and it worked.
The procedure
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.