Forum Stats

  • 3,770,099 Users
  • 2,253,066 Discussions
  • 7,875,313 Comments

Discussions

"show ddl" reports incorrect settings after "set ddl off"

Erik van Roon
Erik van Roon Member Posts: 59 Blue Ribbon

Not the most serious of problems, but still:

Just noticed that "show ddl" does not show the current settings after a "set ddl off" has been performed.

See testcase and screenshots below....

Test case

-- create a test table

create table ero_test_ddl

(col_1 number     primary key

,col_2 number

,col_3 varchar2(30)

,col_4 date

);

-- Check ddl setting

show ddl

-- (all options are set to ON by default)

-- get the ddl for the table

ddl ero_test_ddl

-- (Output as expected: 'pretty' and including segment attributes)

-- change some options

set ddl segment_attributes off

set ddl pretty off

-- Check ddl setting

show ddl

-- (pretty and segment_attributes now set to OFF)


-- get the ddl for the table

ddl ero_test_ddl

-- (Output as expected: 'ugly' and without segment attributes)

-- Let's use "set ddl off"

set ddl off

-- (response is "Default settings for DDL generation have been reset")

-- get the ddl for the table

ddl ero_test_ddl

-- (Output corresponds to the options being reset:

-- 'pretty' and including segment attributes)

-- But now let's look at the ddl settings again

show ddl

-- (pretty and segment_attributes STILL set to OFF, though behavior is ON)

So current settings of DDL not correctly reported !

Philipp Salvisberg