Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

In Sql developer it is possible to get DDL for an existing table -

enter image description here

However, how do I get SQL for operations performed through UI? For example, how do I see DDL generated when I alter the table to drop a column? Sql developer does the drop operation and does not show me anything.

Edit: I add a column -

enter image description here

And then switch over to SQL tab -

enter image description here

Not what I want.

share|improve this question

3 Answers 3

Right click on the table name in the left pane and select

Table -> Generate Table API

Hope this helps!!

share|improve this answer

Look at these packages:

DBMS_METADATA - get_ddl function

DBMS_METADATA_DIFF

DBMS_METADATA_UTIL

share|improve this answer

Oracle knew you wanted this feature. I'm using SQL Developer 4.0.0.13.80 and it works like you want it to. You were probably using an older version when you posted your question. I go to Edit Table, add a column in the GUI, and then pick the item called DDL in the dialog. There is a radio button to show either the full CREATE statement DDL, or just the DDL update for the current edit.

enter image description here

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.