Questions Exam – FULL PRACTICE SET 100%
VERIFIED CORRECT ANSWERS |INSTANT
DOWNLOAD PDF 2025/2026
1. Which SQL statement is used to retrieve data from a database?
a) INSERT
b) UPDATE
c) SELECT
d) DELETE
Answer: c) SELECT — This is the correct statement to retrieve data.
2. Which clause is used to filter the rows returned by a SELECT query?
a) FROM
b) WHERE
c) GROUP BY
d) ORDER BY
Answer: b) WHERE — The WHERE clause filters rows based on a condition.
3. What does NULL represent in an Oracle database?
a) Zero value
b) Empty string
c) Unknown or missing value
d) Default value of a column
Answer: c) Unknown or missing value — NULL means the value is not known
or is missing.
,4. Which of these is a valid Oracle data type for storing fixed-length
character data?
a) VARCHAR2
b) DATE
c) CHAR
d) BLOB
Answer: c) CHAR — CHAR is used for fixed-length character strings.
5. If you want to add a new column age to an existing table STUDENTS,
which SQL command would you use?
a) UPDATE TABLE STUDENTS ADD age NUMBER;
b) ALTER TABLE STUDENTS ADD (age NUMBER);
c) CREATE COLUMN age IN STUDENTS;
d) INSERT INTO STUDENTS (age) VALUES …
Answer: b) ALTER TABLE STUDENTS ADD (age NUMBER); — ALTER TABLE is
used to modify table structure.
6. Which of these is a valid way to remove duplicate rows in a SELECT query?
a) SELECT DISTINCT column_name FROM table;
b) SELECT UNIQUE column_name FROM table;
c) SELECT DIFFERENT column_name FROM table;
d) SELECT column_name ONLY ONCE FROM table;
Answer: a) SELECT DISTINCT column_name FROM table; — DISTINCT
ensures duplicates are removed.
7. What is the default sort order when using ORDER BY in SQL?
a) Descending
b) Ascending
c) No order
d) Random
Answer: b) Ascending — By default ORDER BY sorts in ascending order
unless specified otherwise.
8. Which SQL function would you use to count the number of rows in a
table?
, a) SUM()
b) COUNT()
c) MAX()
d) AVG()
Answer: b) COUNT() — COUNT returns the number of rows.
9. Which clause groups rows that have the same values in specified columns
into summary rows?
a) WHERE
b) ORDER BY
c) GROUP BY
d) HAVING
Answer: c) GROUP BY — GROUP BY is used to aggregate rows based on a
column or set of columns.
10.In Oracle, which SQL statement is used to remove a table and all its data
permanently?
a) DROP TABLE table_name;
b) DELETE TABLE table_name;
c) REMOVE TABLE table_name;
d) TRUNCATE TABLE table_name;
Answer: a) DROP TABLE table_name; — DROP TABLE deletes the table
definition and data permanently.
11.Which of the following is used to prevent accidental data loss when
deleting rows?
a) COMMIT
b) ROLLBACK
c) SAVEPOINT
d) DROP
Answer: b) ROLLBACK — ROLLBACK undoes changes in a transaction before
they are committed.
12.Which command permanently saves changes in the database?
a) COMMIT