SQL Server Query MCQs

Question 16: Write a query to create a new user 'Nancy' in the HR database for Login 'David'.

Question 17: Identify the valid query to assign SELECT permission to user Nancy on the Employee table in the HR database.

Question 18: Write a query to display the FirstName and LastName of the Employee table as a single column as LastName, FirstName

Question 19: How do you delete a UNIQUE constraint named UNQ_Email in the Employee table using T-SQL?

Question 20: Using a subquery, write a query to fetch all employees (Empid, FirstName, Salary) from the Employee table having a salary less than the average salary.