Q1
True / FalseIn Oracle, a primary key is a column or a set of columns that uniquely identifies each row in a table.
A primary key is used to uniquely identify each row in a table and ensures that no duplicate or NULL values exist in the primary key columns.
Q2
True / FalseIn Oracle, a table can have multiple primary keys.
A table can have only one primary key, although that primary key can consist of multiple columns (composite key).
Q3
True / FalseThe primary key in Oracle automatically creates a unique index on the primary key column(s).
When a primary key is defined, Oracle automatically creates a unique index on the primary key column(s) to enforce uniqueness and improve query performance.
Q4
True / FalseIn Oracle, the primary key constraint can be defined at the column level or the table level.
The primary key constraint can be specified directly in the column definition or separately after all column definitions at the table level.
Q5
True / FalseIn Oracle, a primary key column can contain NULL values.
Primary key columns cannot contain NULL values. Each value in the primary key column(s) must be unique and non-NULL.
Q6
True / FalseIn Oracle, you can add a primary key constraint to an existing table using the ALTER TABLE statement.
You can add a primary key constraint to an existing table using the ALTER TABLE statement with the ADD CONSTRAINT clause.
Q7
True / FalseIn Oracle, if a primary key constraint is defined on multiple columns (composite key), the combination of values in those columns must be unique.
A composite primary key ensures that the combination of values in the specified columns is unique across all rows in the table.
Q8
True / FalseIn Oracle, you can create a primary key on a column that already has a unique constraint.
While a column with a unique constraint can serve the purpose of uniqueness, it cannot be directly converted into a primary key if it is already part of a composite unique constraint or if there are NULL values present.
Q9
True / FalseDropping a primary key constraint in Oracle also drops the unique index associated with the primary key.
Dropping a primary key constraint in Oracle will also drop the unique index that was created to enforce the primary key constraint.
Q10
True / FalseThe Oracle Certified Professional (OCP) exam includes knowledge on creating, modifying, and managing primary key constraints, as well as understanding their impact on database integrity and performance.
The OCP certification covers advanced topics, including the creation, modification, and management of primary key constraints, and understanding their impact on data integrity and query performance.
Q25
Multiple ChoiceChoose the SQL statements that demonstrate the importance of primary keys in table relationships.
Primary keys are essential in establishing relationships between tables by acting as a reference point in foreign key constraints. The correct SQL statements will define and utilize the primary key in this context.
Q28
Multiple ChoiceWhich of the following SQL statements correctly create a partitioned table?
Partitioning tables based on primary keys can significantly improve performance by distributing the data across multiple storage segments. The correct SQL statements will include the partitioning clauses.