RE: Dumping contents of a view to CSV file

From: <rajendra.pande_at_ubs.com>
Date: Thu, 27 Oct 2011 12:31:39 -0400
Message-ID: <D4C8B99EB96F2C42B4E19A3B87664F5E027542CF_at_NSTMC612PEX.ubsamericas.net>



Look for ociuldr

-----Original Message-----

From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Rivenes, Andy Sent: Thursday, October 27, 2011 11:50 AM To: sjwales_at_comcast.net; oracle-l_at_freelists.org Subject: RE: Dumping contents of a view to CSV file

You can use Tom Kyte's unloader utility: http://preview.tinyurl.com/6ykgpbg

Regards,

Andy Rivenes

-----Original Message-----

From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Steve Wales Sent: Wednesday, October 26, 2011 3:00 PM To: oracle-l_at_freelists.org
Subject: Dumping contents of a view to CSV file

Hello,  

I've been tasked with generating a CSV file with the contents of a view in
an old database as an extra copy before the DB is decommissioned.  

I've done this in the past for smaller tables or views without issue.  

There are 80 million rows in the view, full row length is 5500 bytes (most
probably shorter since the columns on the base tables are mostly varchar2).  

Doing the math on that, that's a maximum possible size of 440GB.  

I had seen a stored procedure on a website somewhere that read through a cursor and dumped the records out to a text file via utl_file.put. Anyone
have a better method or is that my best option ? I've had some TEMP tablespace failures, I may just need to allocate a bunch of space in temp,
kick it off one afternoon and let it run overnight.  

I've could shrink the overall output size of the file by running "trim" on
the columns too.  

Any ideas appreciated.  

Environment: Oracle 9.2.0.7 on HP-UX 11.11  

Thanks
Steve

--

http://www.freelists.org/webpage/oracle-l

--

http://www.freelists.org/webpage/oracle-l

Please visit our website at
http://financialservicesinc.ubs.com/wealth/E-maildisclaimer.html for important disclosures and information about our e-mail policies. For your protection, please do not transmit orders or instructions by e-mail or include account numbers, Social Security numbers, credit card numbers, passwords, or other personal information.
--

http://www.freelists.org/webpage/oracle-l Received on Thu Oct 27 2011 - 11:31:39 CDT

Original text of this message