Can we use where and having clauses in a single SAS program.
ex: proc sql;
select a,b,c from test
where state in 'KA'
and having <some condition>.
Is the above program run correctly, if not why ?
Answer Posted / rajasekaran
having statement should mentioned after group by statement only
proc sql;
select a,b,c from test
where state in 'KA'
group by xyz
and having <some condition>.
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
How do you add a number to a macro variable? : sas-macro
hi here is a problem can anybody solve this? i want to report the data through third party file. by using data _null_ or proc report or macro automation process. but i want to insert the 'titles and footnotes' in between the data and also starting of 2nd and ending of 2nd and starting of 3rd and ending of the 3rd page. tell me how and write the code?
how will you locate the sas platform applications? : Sas-bi
what is the limit of the number of the rows and columns available in the worksheet? : Sas-bi
what is PhaseIII, ODS, TLG, Macro and Proc in SAS
how many types of prompts are there? : Sas-bi
Name validation tools used in SAS
how are numeric and character missing values represented internally? : Sas programming
How sas treats the dsd delimiters?
explain what is factor analysis? : Sas-administrator
What commands are used in the case of including or excluding any specific variables in the data set?
explain the difference between proc means and proc summary?
explain the key concept of sas? : Sas-administrator
what is operational data and operational system? : Sas-di
how do you test for missing values? : Sas programming