Re: Why use Pro*C for spooling result sets to flat files when you can do the same thing in SQL*Plus?

  • From: Jared Still <jkstill@xxxxxxxxx>
  • To: greg@xxxxxxxxxxxxxxxxxx
  • Date: Thu, 2 Sep 2010 09:11:33 -0700

On Thu, Sep 2, 2010 at 7:40 AM, Greg Rahn <greg@xxxxxxxxxxxxxxxxxx> wrote:

> Because it's faster.  SQL*Plus is not very efficient when it comes to
> formatting.

All true, but there are a lot of details missing the the DBA's terse answer.

Outputting rows faster is not very important if there are only 100 of them
to put in the file.
Banging this out in an sqlplus script generally takes less time than messing
about in ProC.

Now if you need to output a lot of large files, then output speed obviously
becomes important.

'Faster' is always a relative term, but you already knew that. :)

Personally, I would do it in Perl, where it is both simple and fast.  :)

Jared Still
Certifiable Oracle DBA and Part Time Perl Evangelist
Oracle Blog:
Home Page:

Other related posts: