Skip to content
Advertisement

ALTER TABLE SQL Oracle – 12c

we are confused with below answers.so our answer is 3, 5

Which three actions can you perform by using the ALTER TABLE command?

1- Lock a set of rows in a table.

2- Drop pseudocolumns from a table.

3- Rename a table.

4- Drop all columns simultaneously from a table.

5- Enable or disable constraints on a table.

6- Restrict all DML statements on a table.

Thank you

Advertisement

Answer

3, 5 and 6


  1. Lock a set of rows in a table.

    Oracle locks rows it is performing DML on or when you use SELECT ... FOR UPDATE; you cannot lock rows with ALTER TABLE.

  2. Drop pseudocolumns from a table.

    The common pseudocolumns of a table are ROWID, ROWNUM and ORA_ROWSCN; you cannot drop these.

  3. Rename a table.

    Works.

  4. Drop all columns simultaneously from a table.

    Outputs:

  5. Enable or disable constraints on a table.

    Will disable the constraint.

  6. Restrict all DML statements on a table.

    Then

    all fail with the exception:

db<>fiddle here

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement