The issues with dbms_metadata are numerous. I found view extraction in 9i and 10g so buggy that I wrote my own procedure.
However, it is not all dbms_metadata's fault, sometimes it is the text of the view definition itself. For example, if the column list is like "COLUMN1","COLUMN2","COLUMN3", with no spaces between the column names, where should dbms_metadata put in the line break? To us mere humans, it is pretty obvious...but the program does not have a built in rule (perhaps it should) to look at a , as a candidate for line breaks.
-- Daniel Fink Oracle Performance, Diagnosis and Training OptimalDBA http://www.optimaldba.com Oracle Blog http://optimaldba.blogspot.com Join me at Miracle Scotland DB Forum! http://www.miracleltd.com/index.asp?page=167&page2=343 Binh Pham wrote:
I issue these statements:SQL> execute DBMS_METADATA.SET_TRANSFORM_PARAM(DBMS_METADATA.SESSION_TRANSFORM,'PRETTY',true);SQL> select dbms_metadata.get_ddl('VIEW','AP_TAX_LINES_SUMMARY_V','APPS') from dualThe output does not look PRETTY at all.Does it only work with certain object types? This is the description of the option:PRETTY (all objects) - If TRUE, format the output with indentation and line feeds.Defaults to TRUE. Thanks. ------------------------------------------------------------------------Catch suspicious messages before you open them---with Windows Live Hotmail. <http://g.msn.com/8HMAENUS/2734??PS=47575> -- //www.freelists.org/webpage/oracle-l