SQL Quiz

SQL Quiz

University

15 Qs

quiz-placeholder

Similar activities

URL-BD1-SegundoParcial

URL-BD1-SegundoParcial

University

20 Qs

Aaruth Quiz

Aaruth Quiz

University

10 Qs

TES .NET

TES .NET

12th Grade - University

20 Qs

Sql Set 2

Sql Set 2

University

10 Qs

Challenge Yourself

Challenge Yourself

University

20 Qs

SQL set 3

SQL set 3

University

10 Qs

AlterU - Mysql

AlterU - Mysql

1st Grade - Professional Development

20 Qs

BAnDS Tournament Round 3

BAnDS Tournament Round 3

University - Professional Development

10 Qs

SQL Quiz

SQL Quiz

Assessment

Quiz

Other

University

Easy

Created by

M.D.T Production

Used 1+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the full form of SQL?

  1. Structured Query List

  1. Structure Query Language

  1. Sample Query Language

  1. None of these.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is not a valid SQL type?

  1. FLOAT

  1. NUMERIC

  1. DECIMAL

  1. CHARACTER

Answer explanation

DECIMAL is not a valid SQL type because it is nothing but numeric only in SQL.

NUMERIC has fixed precision, and scale numbers range from -10^38+1 to 10^38-1.

FLOAT has floating precision number ranges from -1.79E + 308 to 1.79E + 308.

CHARACTER is a fixed-width character string data type that can be up to 8000 characters.

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is not a DDL command?

  1. TRUNCATE

  1. ALTER

  1. CREATE

  1. UPDATE

Answer explanation

DDL commands are used to define the structure of the database, table, schemas, etc. It enables us to perform the operations like CREATE, DROP, ALTER, RENAME, and TRUNCATE schema objects.

An UPDATE command is used for managing the data stored in a database. It is an example of a DML command that also includes the INSERT and DELETE commands.

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following are TCL commands?

  1. COMMIT and ROLLBACK

  1. UPDATE and TRUNCATE

  1. SELECT and INSERT

  1. GRANT and REVOKE

Answer explanation

TCL stands for Transaction Control Commands used for managing the changes made by DML commands like INSERT, DELETE, and UPDATE. The TCL commands are automatically committed in the database; that's why we cannot use them directly while creating tables or dropping them.

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which statement is used to delete all rows in a table without having the action logged?

  1. DELETE

  1. REMOVE

  1. DROP

  1. TRUNCATE

Answer explanation

TRUNCATE statement removes all rows in a table without logging the individual row deletions. It uses fewer system and transaction log resources, which makes its execution fast. This statement is similar to the DELETE statement without the WHERE clause.

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many Primary keys can have in a table?

  1. Only 1

  1. Only 2

  1. Depends on no of Columns

  1. Depends on DBA

Answer explanation

The primary key can consist of a single or combination of the field that uniquely identifies each record in a table. It cannot be null or empty. A table may have duplicate columns, but it can contain only one primary key.

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which datatype can store unstructured data in a column?

  1. CHAR

  1. RAW

  1. NUMERIC

  1. VARCHAR

Answer explanation

RAW datatype stores variable-length binary data that can be queried and inserted but not manipulated.

Its maximum length is 32767 bytes.

CHAR stores character data in a fixed length.

NUMERIC stores numeric values only.

VARCHAR stores variable string data in a fixed length. Its maximum length is 4000 bytes.

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?