CREATE TABLE dept (deptno NUMBER(2), dname VARCNAR2(14), 1oc VARCNAR2 (13)); ROLLBACK; DESCRIBE DEPT What is true about the set? ()A、The DESCRIBE DEPT statement displays the structure of the DEPT table.B、The ROLLBACK statement frees the storage space occupies by the DEPT table.C、The DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.D、The DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

CREATE TABLE dept (deptno NUMBER(2), dname VARCNAR2(14), 1oc VARCNAR2 (13)); ROLLBACK; DESCRIBE DEPT What is true about the set? ()

  • A、The DESCRIBE DEPT statement displays the structure of the DEPT table.
  • B、The ROLLBACK statement frees the storage space occupies by the DEPT table.
  • C、The DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.
  • D、The DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

相关考题:

Evaluate the SQL statement DROP TABLE DEPT: Which four statements are true of the SQL statement? () A. You cannot roll back this statement.B. All pending transactions are committed.C. All views based on the DEPT table are deleted.D. All indexes based on the DEPT table are dropped.E. All data in the table is deleted, and the table structure is also deleted.F. All data in the table is deleted, but the structure of the table is retained.G. All synonyms based on the DEPT table are deleted.

Which SQL statement defines the FOREIGN KEY constraint on the DEPTNO column of the EMP table? () A. CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) NOT NULL CONSTRAINT emp_deptno_fk FOREIGN KEY deptno REFERENCES dept deptno);B. CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));C. CREATE TABLE EMP (empno NUMBER(4) ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk REFERENCES dept (deptno) FOREIGN KEY (deptno));D. CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp deptno fk REFERENCES dept (deptno));

Scott issues the SQL statements:CREATE TABLE dept(deptno NUMBER(2),dname VARCHAR2(14),loc VARCHAR2(13)};GRANT SELECTON DEPTT0 SUE;If Sue needs to select from Scott‘s DEPT table, which command should she use?()A.SELECT*FROMDEPT;B.SELECT*FROMSCOTT.DEPT;C.SELECT*FROMDBASCOTTDEPT;D.SELECT*FROMALL_USERSWHEREUSER_NAME=‘;SCOTT‘;ANDTABLENAME=‘;DEPT‘;;

Evaluate the set of SQL statements:What is true about the set?() A. The DESCRIBE DEPT statement displays the structure of the DEPT table.B. The ROLLBACK statement frees the storage space occupies by the DEPT table.C. The DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.D. The DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

● 部门DEPT(Deptno, Name, Tel, Leader) 和职工EMP(Empno, Name, Sex, Address, Deptno) 实体集,若一个职工只能属于一个部门,部门负责人 Leader 是一个职工。关系DEPT和EMP的外码分别为 (30) ;下图中a、b处的实体名分别为 (31) 。(30)A. Deptno、EmpnoB. Name、 DeptnoC. Leader、DeptnoD. Name、 Address(31)A. DEPT、EmpnoB. DEPT、EMPC. EMP、DeptnoD. EMP、DEPT

Given the following requirements:Create a table to contain employee data, with a unique numeric identifier automatically assigned when a row is added, has an EDLEVEL column that permits only the values ‘C‘, ‘H‘ and ‘N‘, and permits inserts only when a corresponding value for the employee‘s department exists in the DEPARTMENT table.Which of the following CREATE statements will successfully create this table?()A.CREATE TABLE emp ( empno SMALLINT NEXTVAL GENERATED ALWAYS AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3) NOT NULL, edlevel CHAR(1), PRIMARY KEY emp_pk (empno), FOREIGN KEY emp_workdept_fk ON (workdept) REFERENCES department (deptno), CHECK edlevel_ck VALUES (edlevel IN (‘C‘,‘H‘,‘N‘)), );B.CREATE TABLE emp ( empno SMALLINT NOT NULL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3), edlevel CHAR(1), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY (workdept) REFERENCES department (deptno), CONSTRAINT edlevel_ck CHECK edlevel VALUES (‘C‘,‘H‘,‘N‘) );C.CREATE TABLE emp ( empno SMALLINT NEXTVAL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3) NOT NULL, edlevel CHAR(1) CHECK IN (‘C‘,‘H‘,‘N‘)), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY department (deptno) REFERENCES (workdept) );D.CREATE TABLE emp ( empno SMALLINT NOT NULL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3), edlevel CHAR(1), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY (workdept) REFERENCES department (deptno), CONSTRAINT edlevel_ck CHECK (edlevel IN (‘C‘,‘H‘,‘N‘)) );

Evaluate the set of SQL statements: CREATE TABLE dept (deptno NUMBER(2), dname VARCHAR2(14), loc VARCHAR2(13)); ROLLBACK; DESCRIBE DEPT What is true about the set?()A、The DESCRIBE DEPT statement displays the structure of the DEPT table.B、The ROLLBACK statement frees the storage space occupied by the DEPT table.C、The DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.D、The DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

What type of constraint is used to ensure that each row inserted into the EMPLOYEE table with a value in the WORKDEPT column has a row with a corresponding value in the DEPTNO column of the DEPARTMENT table?()A、A check constraint on the EMPLOYEE tableB、A unique constraint on the EMPLOYEE table WORKDEPT columnC、A foreign key reference from the DEPARTMENT tables DEPTNO column to the WORKDEPT column of the EMPLOYEE tableD、A foreign key reference from the EMPLOYEE tables WORKDEPT column to the DEPTNO column of the DEPARTMENT table

语句SELECT * FROM dept WHERE NOT EXISTS (SELECT * FROM emp WHERE deptno=dept.deptno)执行后的结果为()A、只显示存在于EMP表中的部门全部信息B、只显示不存在于EMP表中的部门全部信息C、未返回任何数据D、显示DEPT表中的全部信息

下面的查询中哪一个会产生笛卡尔集()A、SELECT e.empno,e.ename, e.deptno, d.deptno,d.loc  FROM  emp e,dept  d WHERE e.deptno=d.deptnoB、SELECT e.empno, e.ename, e.deptno, d.deptno,d.loc FROM emp  e,dept  dC、SELECT e.empno, e.ename, e.deptno, d.deptno,d.loc FROM emp e,dept d WHERE e.empno=101 and e.deptno=d.deptnoD、SELECT e.empno, e.ename, e.deptno, d.deptno,d.loc FROM emp e,dept  d WHEREe.deptno=d.deptno and d.deptno=60

下面哪一个SQL语句将删除DEPT表中的所有数据,并永久删除DEPT表的整个结构()A、DROP TABLE dept;B、DELETE TABLE dept;C、TRUNCATE TABLE dept;D、DELETE * . * FROM dept; [END CODE]"

Given the following requirements: Create a table to contain employee data, with a unique numeric identifier automatically assigned when a row is added, has an EDLEVEL column that permits only the values 'C', 'H' and 'N', and permits inserts only when a corresponding value for the employee's department exists in the DEPARTMENT table. Which of the following CREATE statements will successfully create this table?()A、CREATE TABLE emp ( empno SMALLINT NEXTVAL GENERATED ALWAYS AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3) NOT NULL, edlevel CHAR(1), PRIMARY KEY emp_pk (empno), FOREIGN KEY emp_workdept_fk ON (workdept) REFERENCES department (deptno), CHECK edlevel_ck VALUES (edlevel IN ('C','H','N')), );B、CREATE TABLE emp ( empno SMALLINT NOT NULL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3), edlevel CHAR(1), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY (workdept) REFERENCES department (deptno), CONSTRAINT edlevel_ck CHECK edlevel VALUES ('C','H','N') );C、CREATE TABLE emp ( empno SMALLINT NEXTVAL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3) NOT NULL, edlevel CHAR(1) CHECK IN ('C','H','N')), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY department (deptno) REFERENCES (workdept) );D、CREATE TABLE emp ( empno SMALLINT NOT NULL GENERATED BY DEFAULT AS IDENTITY, firstname VARCHAR(30) NOT NULL, lastname VARCHAR(30) NOT NULL, workdept CHAR(3), edlevel CHAR(1), CONSTRAINT emp_pk PRIMARY KEY (empno), CONSTRAINT emp_workdept_fk FOREIGN KEY (workdept) REFERENCES department (deptno), CONSTRAINT edlevel_ck CHECK (edlevel IN ('C','H','N')) );

The HR user creates a stand-alone procedure as follows and grants the EXECUTE privilege on the procedureto many database users: CREATE OR REPLACE PROCEDURE create_dept ( v_deptno NUMBER, v_dname VARCHAR2, v_mgrNUMBER, v_loc NUMBER)BEGIN INSERT INTO hr.departments VALUES (v_deptno, v_dname, v_mgr, v_loc); END; The users having permission to execute the procedure are able to insert records into the DEPARTMENTS tableeven though they do not have the INSERT privilege on the table. You want only those users who haveprivileges on the DEPARTMENTS table to be able to execute the procedure successfully.  What would yousuggest to the PL/SQL developers to achieve this()A、Create the procedure with definer’s right.B、Create the procedure with invoker’s right.C、Grant the EXECUTE privilege with GRANT OPTION on the procedure to selected users.D、Create the procedure as part of a PL/SQL package and grant the EXECUTE privilege on the package toselected users

You created the DEPT table by using the following command:   CREATE TABLE scott.dept   (deptno NUMBER(3),   dname VARCHAR2(15),   loc VARCHAR2(15) )   STORAGE (INITIAL 100K NEXT 50K  MAXEXTENTS 10 PCTINCREASE 5  FREELIST GROUPS 6 FREELISTS 4);You are required to shrink the DEPT table. While performing the shrink operation, you want to ensure that the recovered space is returned to the tablespace in which the DEPT table is stored. You do not want to shrink the indexes created on the DEPT table. What will you do to shrink the SCOTT.EMP table?()A、 Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE COMPACT; statement.B、 Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE; statement.C、 Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE CASCADE; statement.D、 You cannot shrink the SCOTT.EMP table.

Evaluate the SQL statement DROP TABLE DEPT: Which four statements are true of the SQL statement? ()A、You cannot roll back this statement.B、All pending transactions are committed.C、All views based on the DEPT table are deleted.D、All indexes based on the DEPT table are dropped.E、All data in the table is deleted, and the table structure is also deleted.F、All data in the table is deleted, but the structure of the table is retained.G、All synonyms based on the DEPT table are deleted.

Scott issues the SQL statements: CREATE TABLE dept (deptno NUMBER(2), dname VARCHAR2(14), loc VARCHAR2(13)}; GRANT SELECT ON DEPT T0 SUE; If Sue needs to select from Scott's DEPT table, which command should she use?()A、SELECT*FROMDEPT;B、SELECT*FROMSCOTT.DEPT;C、SELECT*FROMDBASCOTTDEPT;D、SELECT*FROMALL_USERSWHEREUSER_NAME=';SCOTT';ANDTABLENAME=';DEPT';;

Which SQL statement defines the FOREIGN KEY constraint on the DEPTNO column of the EMP table? ()A、CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) NOT NULL CONSTRAINT emp_deptno_fk FOREIGN KEY deptno REFERENCES dept deptno);B、CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));C、CREATE TABLE EMP (empno NUMBER(4) ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk REFERENCES dept (deptno) FOREIGN KEY (deptno));D、CREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp deptno fk REFERENCES dept (deptno));

单选题Using the report wizard you create a tabular report to display all the columns in the EMP table. The records are ordered by the deptname and job columns. You need to create a hierarchical report that breaks on the deptname and job values. Using the data model how would you create this break structure?()ASpecify the break order on the gemp group Property palette. BSpecify a break order on the dept_name and job columns property palettes. CClick and drag the dept_name and jobs column out and above of the gemp group to create a new parent group. DChange the position of the dept_name and the job columns within the gemp group.

单选题Scott issues the SQL statements: CREATE TABLE dept (deptno NUMBER(2), dname VARCHAR2(14), loc VARCHAR2(13)}; GRANT SELECT ON DEPT T0 SUE; If Sue needs to select from Scott's DEPT table, which command should she use?()ASELECT*FROMDEPT;BSELECT*FROMSCOTT.DEPT;CSELECT*FROMDBASCOTTDEPT;DSELECT*FROMALL_USERSWHEREUSER_NAME=';SCOTT';ANDTABLENAME=';DEPT';;

单选题The HR user creates a stand-alone procedure as follows and grants the EXECUTE privilege on theprocedure to many database users:  CREATE OR REPLACE PROCEDURE create_dept ( v_deptno NUMBER, v_dname VARCHAR2, v_mgr NUMBER, v_loc NUMBER) BEGIN  INSERT INTO hr.departments VALUES (v_deptno, v_dname, v_mgr, v_loc); END;  The users having permission to execute the procedure are able to insert records into the  DEPARTMENTStable even though they do not have the INSERT privilege on the table. You want only those users whohave privileges on the DEPARTMENTS table to be able to execute the procedure successfully.  What would you suggest to the PL/SQL developers to achieve this()ACreate the procedure with definer’s right.BCreate the procedure with invoker’s right.CGrant the EXECUTE privilege with GRANT OPTION on the procedure to selected users.DCreate the procedure as part of a PL/SQL package and grant the EXECUTE privilege on the package to selected users

单选题Which SQL statement defines a FOREIGN KEY constraint on the DEPTNO column of the EMP table?()ACREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk FOREIGN KEY deptno REFERENCES dept deptno);BCREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));CCREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk REFERENCES dept (deptno) FOREIGN KEY (deptno));DCREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));

单选题You created the DEPT table by using the following command:   CREATE TABLE scott.dept   (deptno NUMBER(3),   dname VARCHAR2(15),   loc VARCHAR2(15) )   STORAGE (INITIAL 100K NEXT 50K  MAXEXTENTS 10 PCTINCREASE 5  FREELIST GROUPS 6 FREELISTS 4);You are required to shrink the DEPT table. While performing the shrink operation, you want to ensure that the recovered space is returned to the tablespace in which the DEPT table is stored. You do not want to shrink the indexes created on the DEPT table. What will you do to shrink the SCOTT.EMP table?()A Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE COMPACT; statement.B Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE; statement.C Issue the ALTER TABLE SCOTT.DEPT SHRINK SPACE CASCADE; statement.D You cannot shrink the SCOTT.EMP table.

单选题CREATE TABLE dept (deptno NUMBER(2), dname VARCNAR2(14), 1oc VARCNAR2 (13)); ROLLBACK; DESCRIBE DEPT What is true about the set? ()AThe DESCRIBE DEPT statement displays the structure of the DEPT table.BThe ROLLBACK statement frees the storage space occupies by the DEPT table.CThe DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.DThe DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

多选题Evaluate the SQL statement DROP TABLE DEPT: Which four statements are true of the SQL statement? ()AYou cannot roll back this statement.BAll pending transactions are committed.CAll views based on the DEPT table are deleted.DAll indexes based on the DEPT table are dropped.EAll data in the table is deleted, and the table structure is also deleted.FAll data in the table is deleted, but the structure of the table is retained.GAll synonyms based on the DEPT table are deleted.

单选题On Monday, you dropped the DEPT table from your schema and then you re/x7fcreated the DEPT table in your schema. On Wednesday, you have a requirement to restore the DEPT table from the recycle bin. Which statement is correct?()AYou can restore the DEPT table by using the Oracle Flashback Drop feature, provided you use the RENAME TO clause.BYou can restore the DEPT table by using the Oracle Flashback Drop feature and a system­generated name will be assigned to the restored table.CYou cannot restore the DEPT table by using the Oracle Flashback Drop feature because a table withthe name DEPT already exists in your schema.DYou cannot restore the DEPT table by using the Oracle Flashback Drop feature because the contents of the recycle bin are purged every 12 hours by default.

单选题Evaluate the set of SQL statements: CREATE TABLE dept (deptno NUMBER(2), dname VARCNAR2(14), 1oc VARCNAR2 (13)); ROLLBACK; DESCRIBE DEPT What is true about the set?()AThe DESCRIBE DEPT statement displays the structure of the DEPT table.BThe ROLLBACK statement frees the storage space occupies by the DEPT table.CThe DESCRIBE DEPT statement returns an error ORA-04043: object DEPT does not exist.DThe DESCRIBE DEPT statement displays the structure of the DEPT table only if there is a COMMIT statement introduced before the ROLLBACK statement.

单选题Which SQL statement defines the FOREIGN KEY constraint on the DEPTNO column of the EMP table?()ACREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) NOT NULL CONSTRAINT emp_deptno_fk FOREIGN KEY deptno REFERENCES dept deptno);BCREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));CCREATE TABLE EMP (empno NUMBER(4) ename VARCHAR2(35), deptno NUMBER(7,2) NOT NULL, CONSTRAINT emp_deptno_fk REFERENCES dept (deptno) FOREIGN KEY (deptno));DCREATE TABLE EMP (empno NUMBER(4), ename VARCNAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp deptno fk REFERENCES dept (deptno));

单选题What type of constraint is used to ensure that each row inserted into the EMPLOYEE table with a value in the WORKDEPT column has a row with a corresponding value in the DEPTNO column of the DEPARTMENT table?()AA check constraint on the EMPLOYEE tableBA unique constraint on the EMPLOYEE table WORKDEPT columnCA foreign key reference from the DEPARTMENT tables DEPTNO column to the WORKDEPT column of the EMPLOYEE tableDA foreign key reference from the EMPLOYEE tables WORKDEPT column to the DEPTNO column of the DEPARTMENT table