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: Outputting a table/recordset to a csv

Re: Outputting a table/recordset to a csv

From: Billy Verreynne <vslabs_at_onwe.co.za>
Date: Tue, 22 Oct 2002 07:53:06 +0200
Message-ID: <ap2p5h$1ff$3@ctb-nnrp2.saix.net>


Aidan Whitehall wrote:

> Forgive the beginner's Q... trawled Google groups and got this far
> (below), but it doesn't work. I'm just trying to output a recordset to a
> text file. Ideally, I'd like the whole table but the examples that turned
> up specified the column names.

You unfortunately need to code in all the column names and column separators and also include enclosed quotes where needed...

> Anyone care to point out the stupid mistake(s) I'm making? I've no idea
> what the first seven lines do, BTW. Thanks.
<snipped>

Karsten explain it very well. You can also look at the SQL*Plus manual for more info. This is usually available via PDF or HTML with the Oracle installation.

> select st_site_id || ',' || ow_owner_id || ',' || hsg_assessment_date
> from hsg146;

This statement seems fine. What is the error that you got? What does the content of the "C:\temp.csv" has to say?

--
Billy
Received on Tue Oct 22 2002 - 00:53:06 CDT

Original text of this message

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