Below is the list of some Advanced SAS Interview Questions. It helps to test the knowledge on advanced SAS topics.
1) Name the incorrect clause of the below program.
proc sql:
select gender,mean(height) as avgheight
from class.students class.health
where students.id=student.id
group by gender;
A) GROUP BY
B) WHERE
C) FROM
D) SELECT
Ans. C
2) Select the clause that specifies the tables of Fruits and Vegetables to be queried. libref Quantity is the library assigned for these tables.
A) where quantity.fruits, quantity.vegetables
B) from quantity.fruits, quantity.vegetables
C) from quantity.fruits quantity.vegetables
D) select quantity.fruits quantity.vegetables
Ans. B
Advanced SAS Interview Questions
3) There are —— statements in the below program.
proc sql;
select pens, pencils,
pens + pencils as sumsales
from sales.manufacture
order by sumsales;
A) Two
B) Four
C) Six
D) Eight
Ans. A
4) List the incorrect clause from the below program.
proc sql;
select style sqyard classrooms
from choice.schools
where sqyard ge 700;
A) WHERE
B) SELECT
C) FROM
D) Both A & B
Ans. B
5. Which are the clauses below that sort rows by column’s values
A) Sort cost books
B) Sort by cost books
C) Order by cost,books
D) Order cost, books
Ans. C
6. In PROC SQL, if a summary function is missing along with the GROUP BY clause, then the following happens
A) Grouping or sorting of data will not occur, though the step executes
B) The clause will convert from GROUP BY to ORDER BY
C) There will be default summing of the first numeric column
D) The step will not execute
Ans. B
7. The statement below enables PROC SQL to generate rows without data in the Class column.
A) WHERE class is null
B) WHERE class is missing
C) WHERE class not exist
D) both A & B
Ans. D
8) Identify the false statement from the below PROC SQL query.
proc sql;
validate
select name label = ‘Company’
rate label = ‘Turnover Rate’
from companies.turnover
where ‘manufacturer’ =
(select manufacturers
from companies.manufacturers
where turnover.name =
manufacturers.company)
order by 2;
A) Invalid Syntax
B) Cannot Execute
C) Subquery requires values before returning values
D) After submitting the query, the log will determine whether the syntax is valid
Ans. A
9) Identify the correct statement about the data remerging in proc SQL.
A) Remerging of data is possible only by using the subquery
B) During remerging of data, the SAS log displays the related message
C) Use of data remerging helps in avoiding creating two passes by the data
D) During data remerging, data from two different tables is combined
Ans. B
10) A noncorrelated subquery, a nested query,
A) necessitates the outer query to pass a single value
B) Executes independently without the need for an outer query
C) Holds a minimum of a single summary function
D) Returns one single value to the outer query
Ans. B
To get training in Clinical SAS, click on the link.
The training includes the following,
1) BASE & ADVANCED SAS TRAINING (Technical Part) – 2Months
2) CLINICAL SAS TRAINING (Domain Part) – 2Months
Schedule: Three days per week or weekend classes.
To listen to the explanation of solving SAS interview questions, click on the link for a sample video.