Database Administration (MOSC)

MOSC Banner

unused columns in version 11.2.0.4

edited Jun 17, 2015 2:12PM in Database Administration (MOSC) 2 commentsAnswered ✓

Hello

I have not done much work with unusable columns so I am trying to test is before implementing in production environment

Here is my test

select * from test4;

      COL1       COL2

---------- ----------

         1          1

         1          1

         1          1

         2          3

alter table test4 set unused (col2);

Table altered.

select * from test4;

      COL1

----------

         1

         1

         1

         2

alter table test4 add col2 number;

Table altered.

select * from test4;

      COL1       COL2

---------- ----------

         1

         1

         1

         2

alter table test4 drop unused columns;

Table altered.

select * from test4;

      COL1       COL2

---------- ----------

         1

         1

         1

         2

For some reason I was under impression that once I have made a column unused I can not add it to the table. Is that an incorrect assumption (based on my quick test) or is my test flawed?

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center