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 will you use the WHO Drug Dictionary for Reporting Clinical Trials?
Differentiate input and infile.
What is the command used to find missing values?
what do the sas log messages "numeric values have been converted to character" mean? What are the implications? : Sas programming
What are the functions used for character handling?
what is sas database server? : Sas-di
In SAS explain which statement does not perform automatic conversions in comparisons?
How would you code a merge that will write the matches of both to one data set, the non-matches from the left-most data?
Can you execute a macro within a macro? Describe. : sas-macro
What is the order of application for output data set options, input data set options and SAS statements?
What are the functions which are used for character handling functions?
what are informats in sas? : Sas-administrator
explain the function of substr in sas? : Sas-administrator
What does the trace option do?
Which date function advances a date, time or datetime value by a given interval?