DBMS-Microsoft SQL Server Questions and Answers

Practice Mode
Showing 10 of 49 questions
Q21
Which operator is used to search for a specified pattern in a column?
  • A MATCH
  • B SIMILAR
  • C PATTERN
  • D LIKE
Answer: Option D
Explanation: LIKE operator searches for specified patterns using wildcards.
Q22
Which statement is used to remove a table from database?
  • A REMOVE
  • B DELETE
  • C DROP TABLE
  • D ERASE
Answer: Option C
Explanation: DROP TABLE statement completely removes a table from the database.
Q23
Which clause is used to group rows that have same values?
  • A CATEGORIZE
  • B COMBINE
  • C GROUP BY
  • D COLLECT
Answer: Option C
Explanation: GROUP BY groups rows that have same values into summary rows.
Q24
Which function returns the current date and time?
  • A CURRENT()
  • B NOW()
  • C GETDATE()
  • D TODAY()
Answer: Option C
Explanation: GETDATE() returns current date and time in SQL Server.
Q25
Which constraint uniquely identifies each record in a table?
  • A UNIQUE
  • B PRIMARY KEY
  • C IDENTITY
  • D MAIN
Answer: Option B
Explanation: PRIMARY KEY uniquely identifies each record in a table.
Q26
Which keyword is used to change the structure of a table?
  • A MODIFY
  • B CHANGE
  • C ALTER TABLE
  • D UPDATE
Answer: Option C
Explanation: ALTER TABLE modifies the structure of an existing table.
Q27
Which wildcard character represents zero or more characters?
  • A *
  • B #
  • C %
  • D ?
Answer: Option C
Explanation: Percent sign (%) represents zero or more characters in pattern matching.
Q28
Which function converts a value to uppercase?
  • A TOUPPER()
  • B UPPER()
  • C CAPITAL()
  • D UCASE()
Answer: Option B
Explanation: UPPER() function converts string to uppercase.
Q29
Which join returns all records from both tables?
  • A INNER JOIN
  • B LEFT JOIN
  • C RIGHT JOIN
  • D FULL JOIN
Answer: Option D
Explanation: FULL JOIN returns all records when there is a match in either left or right table.
Q30
Which SQL statement is used to retrieve data from a database?
  • A GET
  • B SELECT
  • C EXTRACT
  • D OPEN
Answer: Option B
Explanation: SELECT statement is used to query and retrieve data from database tables.
Database
Back to Database
Questions and Answers for Competitive Exams Various Entrance Test