Tag: databases

Questions Related to databases

  1. a single table in the database

  2. to all tables in the database

  3. to all the tables of the user

  4. more than one table in the database


Correct Option: B
  1. ORDER BY clause.

  2. GROUP BY clause.

  3. JOIN clause.

  4. WHERE clause.


Correct Option: D
Explanation:

To use the LIKE SQL keyword, the user needs to know that it is used for pattern matching in SQL queries. It is used to search for a specific pattern within a column of a table.

The correct answer is:

D. WHERE clause.

Explanation:

The LIKE keyword is used along with the WHERE clause to filter the results based on a specific pattern. The WHERE clause is used to extract only those records that fulfill a specified condition. The LIKE keyword is used to specify the pattern that the user wants to match.

A. ORDER BY clause: This clause is used to sort the results in ascending or descending order based on one or more columns of a table.

B. GROUP BY clause: This clause is used to group the results based on one or more columns of a table. It is typically used along with aggregate functions like SUM, COUNT, AVG, etc.

C. JOIN clause: This clause is used to combine two or more tables based on a related column between them.

D. WHERE clause: This clause is used to filter the results based on a specific condition. The LIKE keyword is used along with this clause to match a specific pattern within a column.

Therefore, option D is the correct answer.

  1. update database table

  2. verify that the inserted data is correct

  3. select data from 2 or more tables related by common attribute (table column).

  4. delete data from database table


Correct Option: C

We refer to a join as a self-join when…

  1. we are using left and right join together

  2. we are joining more than 2 tables

  3. we are joining table to itself

  4. when joining a table and its view


Correct Option: C
  1. The DELETE clause deletes all rows in a database table, while the TRUNCATE clause can have a WHERE condition and might or might not delete all rows in a table.

  2. The TRUNCATE clause is identical to the DELETE clause

  3. The TRUNCATE clause deletes all rows in a database table, while the DELETE clause can have a WHERE condition and might or might not delete all rows in a table.

  4. None fo the above


Correct Option: C
  1. Creates a database view

  2. Creates a new database table

  3. Creates a stored procedure

  4. Creates a trigger


Correct Option: C
  1. A trigger is part of data extraction process.

  2. A trigger is a special kind of stored procedures executed when certain event occurs.

  3. A trigger defines relations between tables.

  4. A trigger is a part of error handling


Correct Option: C
  1. List of columns that will be selected or the * symbol.

  2. The JOIN SQL clause.

  3. The name of the table we are selecting from.

  4. Selects a database


Correct Option: A

Which clause specifies conditions that determines the groups included in the query?

  1. Having Clause

  2. Where clause

  3. Distinct

  4. Exists


Correct Option: A