1Z0-071 practice question 23 of 35

Which two are true about creating tables in an Oracle database?

Full set: 326 questions
Answer options
A: A create table statement can specify the maximum number of rows the table will contain.
B: The same table name can be used for tables in different schemas. Correct answer
C: A system privilege is required. Correct answer
D: Creating an external table will automatically create a file using the specified directory and file name.
E: A primary key constraint is manadatory.
Correct Answer:
B. The same table name can be used for tables in different schemas.; C. A system privilege is required.
Explanation

In Oracle, a schema acts as a namespace for database objects. Therefore, while a table name must be unique within its own schema, different schemas can contain tables with the same name (e.g., HR.EMPLOYEES and SCOTT.EMPLOYEES). To create a table, a user must possess the appropriate system privilege. The CREATE TABLE system privilege is required to create a table in one's own schema, and the CREATE ANY TABLE system privilege is needed to create a table in another user's schema.

Why Incorrect

A: The CREATE TABLE statement syntax does not include an option to define a maximum number of rows for the table. D: The CREATE EXTERNAL TABLE statement defines metadata for a pre-existing external file; it does not create the physical file itself. E: A primary key constraint is a best practice for ensuring data integrity but is not a mandatory requirement for creating a table.

References

1. Oracle Database SQL Language Reference, 23c, "CREATE TABLE". Under "Prerequisites", it states: "To create a table in your own schema, you must have the CREATE TABLE system privilege. To create a table in another user's schema, you must have the CREATE ANY TABLE system privilege."

2. Oracle Database Concepts, 23c, "Schema Object Naming". This section explains that schema objects of the same type (e.g., tables) must have unique names within a schema, implying they can be non-unique across different schemas.

3. Oracle Database Utilities, 23c, "Creating External Tables". The documentation states, "You use the CREATE TABLE...ORGANIZATION EXTERNAL statement to create an external table." It describes how to map the table to an existing data source file.

Scroll to Top