单选题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*FROMSCOT

题目
单选题
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';;


相似考题
参考答案和解析
正确答案: C
解析: 暂无解析
更多“Scott issues the SQL statements: CREATE TABLE dept (deptno N”相关问题
  • 第1题:

    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‘;;


    参考答案:B

  • 第2题:

    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.

    正确答案:A

  • 第3题:

    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')) );

    正确答案:D

  • 第4题:

    For which two SQL statements can you use the Flashback Table feature to revert a table to its previous state?()

    • A、UPDATE TABLE
    • B、CREATE CLUSTER
    • C、TRUNCATE TABLE
    • D、ALTER TABLE MOVE
    • E、INSERT INTO···VALUES
    • F、ALTER TABLE···DROP COLUMN
    • G、ALTER TABLE···DROP PARTITION

    正确答案:A,E

  • 第5题:

    The DBA issues this SQL command:CREATE USER scott IDENTIFIED by tiger;What privileges does the user Scott have at this point?()

    • A、no privileges
    • B、only the SELECT privilege
    • C、only the CONNECT privilege
    • D、all the privileges of a default user

    正确答案:A

  • 第6题:

    Mary has a view called EMP_DEPT_LOC_VU that was created based on the EMPLOYEES, DEPARTMENTS, and LOCATIONS tables. She granted SELECT privilege to Scott on this view. Which option enables Scott to eliminate the need to qualify the view with the name MARY.EMP_DEPT_LOC_VU each time the view is referenced?()

    • A、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command CREATE PRIVATE SYNONYM EDL_VU FOR mary.EMP_DEPT_LOC_VU; then he can prefix the columns with this synonym.
    • B、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command CREATE SYNONYM EDL_VU FOR mary.EMP_DEPT_LOC_VU; then he can prefix the columns with this synonym.
    • C、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command CREATE LOCAL SYNONYM EDL_VU FOR mary.EMP_DEPT_LOC_VU; then he can prefix the columns with this synonym.
    • D、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command CREATE SYNONYM EDL_VU ON mary(EMP_DEPT_LOC_VU); then he can prefix the columns with this synonym.
    • E、Scott cannot create a synonym because synonyms can be created only for tables.
    • F、Scott cannot create any synonym for Mary's view. Mary should create a private synonym for the view and grant SELECT privilege on that synonym to Scott.

    正确答案:B

  • 第7题:

    Mary has a view called EMP_DEPT_LOC_VU that was created based on the EMPLOYEES, DEPARTMENTS, and LOCATIONS tables. She granted SELECT privilege to Scott on this view. Which option enables Scott to eliminate the need to qualify the view with the name MARY .EMP_DEP_LOC_VU each time the view is referenced?()

    • A、Scott can create a synonym for the EMP_DEPT_LOC_VU bus using the command: CREATE PRIVATE SYNONYM EDL_VU FOR mary.EMP DEPT_LOC_VU; then he can prefix the columns with this synonymn.
    • B、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE SYNONYM EDL_VU FOR mary.EMP_DEPT_LOC_VU; then he can prefix the columns with this synonym.
    • C、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE LOCAL SYNONYM EDL_VU FOR mary.EMP DEPT_LOC_VU; then he can prefix the columns with this synonym.
    • D、Scott can create a synonym for the EMP_DEPT_LOC_VU by using the command: CREATE SYNONYM EDL_VU ON mary(EMP_DEPT_LOC_VU); then he can prefix the columns with this synonym.
    • E、Scott cannot create a synonym because synonyms can be created only for tables.
    • F、Scott cannot create any synonym for Mary's view. Mary should create a private synonym for the view and grant SELECT privilege on that synonym to Scott.

    正确答案:B

  • 第8题:

    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));

    正确答案:B

  • 第9题:

    单选题
    The DBA issues this SQL command: CREATE USER scott IDENTIFIED by tiger; What privileges does the user Scott have at this point?()
    A

    no privileges

    B

    only the SELECT privilege

    C

    only the CONNECT privilege

    D

    all the privileges of a default user


    正确答案: C
    解析: 暂无解析

  • 第10题:

    单选题
    Which SQL statement defines a FOREIGN KEY constraint on the DEPTNO column of the EMP table?()
    A

    CREATE TABLE EMP (empno NUMBER(4), ename VARCHAR2(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 VARCHAR2(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 VARCHAR2(35), deptno NUMBER(7,2) FOREIGN KEY CONSTRAINT emp_deptno_fk REFERENCES dept (deptno));


    正确答案: A
    解析: 暂无解析

  • 第11题:

    单选题
    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.


    正确答案: B
    解析: 暂无解析

  • 第12题:

    单选题
    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?()
    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.


    正确答案: D
    解析: 暂无解析

  • 第13题:

    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.


    参考答案:A

  • 第14题:

    下面哪一个SQL语句将删除DEPT表中的所有数据,并永久删除DEPT表的整个结构()

    • A、DROP TABLE dept;
    • B、DELETE TABLE dept;
    • C、TRUNCATE TABLE dept;
    • D、DELETE * . * FROM dept; [END CODE]"

    正确答案:A

  • 第15题:

    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

    正确答案:B

  • 第16题:

    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.

    正确答案:D

  • 第17题:

    You need to perform these tasks: 1. Create and assign a MANAGER role to Blake and Clark 2. Grant CREATE TABLE and CREATE VIEW privileges to Blake and Clark Which set of SQL statements achieves the desired results?()

    • A、CREATE ROLE manager; GRANT create table, create view TO manager; GRANT manager TO BLACK, CLARK;
    • B、CREATE ROLE manager; GRANT create table, create voew TO manager; GRANT manager ROLE TO BLACK, CLARK;
    • C、GRANT manager ROLE TO BLACK, CLARK; GRANT create table, create voew TO BLACK CLARK; ***MISSING***

    正确答案:A

  • 第18题:

    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.

    正确答案:A,B,D,E

  • 第19题:

    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';;

    正确答案:B

  • 第20题:

    单选题
    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';;


    正确答案: A
    解析: 暂无解析

  • 第21题:

    单选题
    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.


    正确答案: A
    解析: 暂无解析

  • 第22题:

    单选题
    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.


    正确答案: A
    解析: 暂无解析

  • 第23题:

    多选题
    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.


    正确答案: B,E
    解析: 暂无解析

  • 第24题:

    单选题
    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));


    正确答案: C
    解析: 暂无解析