SPOOL [message #556562] |
Tue, 05 June 2012 06:02  |
pointers
Messages: 451 Registered: May 2008
|
Senior Member |
|
|
Hi,
I am pulling out the metadata using dbms_metadata using sqlplus and spool.
select dbms_metadata.get_ddl('PACKAGE','PKG_TEST','SALESABCD') from dual;
I have used the below seetings.
set feedback off
set long 1000000
set trimspool on
SET LINESIZE 32767
SET HEADING OFF
set PAGESIZE 40000
set verify off
set termout off
spool hello.txt
but when I see the output of the spool file the lines are distributed in seperate lines something like below (a sample where line is split across lines).
/*----------------- History of Change ------------------------------------------
------------
As you see above the line size is set to 32767 but still it is not effective.
Could you please advice if i need to add something.
Regards,
Pointers
|
|
|
Re: SPOOL [message #556564 is a reply to message #556562] |
Tue, 05 June 2012 06:10   |
pointers
Messages: 451 Registered: May 2008
|
Senior Member |
|
|
Hi,
I got the solution by using an column alias and extra setting like below.
select dbms_metadata.get_ddl('PACKAGE','PKG_TEST','SALESABCD') a from dual;
column a format a200
1. Is there any other setting we can do to achive this
2. But why do we need to use column format though i have mentioned line size
Thank you very much in advance
Regards,
Pointers
|
|
|
|