11. Which of the following commands is used to change the structure of table?
- CHANGE TABLE
- MODIFY TABLE
- ALTER TABLE
- UPDATE TABLE
12. Consider the following statements and pick the correct answer:
1. ceiling() - returns the smallest integer greater than or equal to the specified value
2. floor() - returns the largest integer less than or equal to the specified value
- 1 is true and 2 is false
- 1 is false and 2 is true
- Both 1 and 2 are true
- Both 1 and 2 are false
13. What is the maximum value that can be stored for a datetime field?
- Dec 31, 9999
- Jun 6, 2079
- Jan 1, 2753
- Jan 1, 2100
14. Consider the following queries:
1. select * from employee where department LIKE "[^F-M]%";
2. select * from employee where department = "[^F-M]%";
Select the correct option:
- Query 2 will return an error
- Both the queries will return the same set of records
- Query 2 is perfectly correct
- Query 2 would return one record less than Query 1
15. How can you view the structure of a table named “myTable” in SQL Server?
- desc myTable
- desc table myTable
- sp_columns myTable
- None of the above
- Using either option a or c
16. What does referential integrity (also called relational integrity) prevent?
- Loss of data from employee sabotage
- Loss of data from any one corrupted table
- Recursive joins
- One-to-many or many-to-many relationships between columns in a table
- Data redundancy
17. Which of the following is not a global variable?
- @@colcount
- @@error
- @@rowcount
- @@version
- All are valid global variables
18. Which of the following is not a control statement?
- if…else
- if exists
- do…while
- while
- begin…end
19. Which of the following is not a valid Numeric datatypes in SQL Server?
- INT
- SMALLINT
- TINYINT
- BIGINT
- MONEY
20. Which of the following datatypes is not supported by SQL-Server?
- Character
- Binary
- Logical
- Date
- Numeric
- All are supported