Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: How to start export from PL/SQL

Re: How to start export from PL/SQL

From: Billy Verreynne <vslabs_at_onwe.co.za>
Date: Wed, 04 Sep 2002 08:48:15 +0200
Message-ID: <al4ac5$qvd$1@ctb-nnrp2.saix.net>

Epicentre team A wrote:

> Is possible to run export (for generate dump) in stored proc.

Yes and no.

The No part. As Sybrand said, export is a "seperate command" (i.e. an external program) and not part of the PL/SQL language.

The Yes part. There are various ways it can be done. You could use a DBMS pipe to talk to a server side process (Unix shell script for example) and ask it to start the export for you. You could use UTL file and write your own CSV file. You could use a BFILE table and do the same. You could create a normal Oracle table for inserting o/s side commands into - this table is then polled by a server process (a good old fashioned sh script for example) that reads this table and performs the command. You could write an external stored proc (callable via PL/SQL) that uses the OCI to perform array fetches and write the contents to file. If the export is to be done client-side, you could do it in the client via an o/s exec call (a fork() on Unix or a CreateProcess() on Win32) to the local export program.

So many possibilities. So many kewl technologies. So little time. Does it not make you horny baby? Does it!? We are sexy bitches! Hmm.. yes we are. Oracle mojo. Oh behave!

--
Billy
Received on Wed Sep 04 2002 - 01:48:15 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US