Which describes the default behavior when you create a table?
The table is accessible to all users.
Tables are created in the public schema.
Tables are created in your schema.
Tables are created in the DBA schema.
The DBA issues this SQL command: CREATE USER Scott IDENTIFIED by tiger; what privileges do the user Scott has at this point?
no privileges
only the SELECT privilege
only the CONNECT privilege
all the privileges of a default user
Examine these statements:
CREATE ROLE registrar;
GRANT UPDATE ON student_grades TO registrar;
GRANT registrar to user1, user2, user3;
What does this set of SQL statements do?
The set of statements contains an error and does not work.
It creates a role called REGISTRAR, adds the MODIFY privilege on the STUDENT_GRADES object to the role, and gives the REGISTRAR role to three users.
It creates a role called REGISTRAR, adds the UPDATE privilege on the STUDENT_GRADES object to the role, and gives the REGISTRAR role to three users.
It creates a role called REGISTRAR, adds the UPDATE privilege on the STUDENT_GRADES object to the role, and creates three users with the role.
Examine the statement:
Create synonym EMP for hr.employees;
What happens when you issue the statement?
An error is generated.
You will have two identical tables in the HR schema with different names.
You create a table called employees in the HR schema based on your EMP table.
You create an alternative name for the employees table in the HR schema in your own schema
You need to create a view EMP_VU. The view should allow the users to manipulate the records of only the employees that are working for departments 10 or 20. Which SQL statement would you use to create the view EMP_VU?
CREATE VIEW emp_vu AS SELECT * FROM employees WHERE department_id IN (10,20);
CREATE VIEW emp_vu AS SELECT * FROM employees WHERE department_id IN (10,20) WITH READ ONLY;
CREATE VIEW emp_vu AS SELECT * FROM employees WHERE department_id IN (10,20) WITH CHECK OPTION;
CREATE FORCE VIEW emp_vu AS SELECT * FROM employees WHERE department_id IN (10,20);]
Which is a valid CREATE TABLE statement?
CREATE TABLE EMP9$# AS (emp_id number(2));
CREATE TABLE EMP*123 AS (emp_id number(2));
CREATE TABLE PACKAGE AS (pack_id number(2));
CREATE TABLE 1EMP_TEST AS (emp_id number(2));
Evaluate the set of SQL statements:
CREATE TABLE dept (
dept_id NUMBER (2),
dname VARCHAR2 (14),
Loc VARCHAR2 (13));
ROLLBACK;
DESCRIBE DEPT;
What is true about the set?
The DESCRIBE DEPT statement displays the structure of the DEPT table
The ROLLBACK statement frees the storage space occupied by the DEPT table.
The DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist
The DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.
When should you create a role?
to simplify the process of creating new users using the CREATE USER xxx IDENTIFIED by yyyy statement
To grant a group of related privileges to a user.
When the number of people using the database is very high
To simplify profile maintenance for a user who is constantly traveling.
You are granted the CREATE VIEW privilege. What does this allow you to do?
create a table view
create a view in any scheme
create a view in your schema
create a sequence view in any schema