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 create a Cobol flatfile in sqlplus

Re: How to create a Cobol flatfile in sqlplus

From: Jerry Gitomer <jgitomer_at_erols.com>
Date: 2000/06/25
Message-ID: <20000625.5181300@p200.nodomain>#1/1

        If I remember correctly the following should work:

                SET COLSEP ''

>>>>>>>>>>>>>>>>>> Original Message <<<<<<<<<<<<<<<<<<

On 6/24/00, 9:51:31 AM, Manfred Friedrich <mfriedrich_at_excite.com> wrote

regarding How to create a Cobol flatfile in sqlplus:

> I would like to create a flatfile out of sqlplus
> from the following table:

> SQL> desc mstest
> Name Null? Type
> ------------------------------- -------- ----
> T VARCHAR2(5)
> II NUMBER(7,2)
> I NUMBER(3)
 
> SQL> select * from mstest;
 

> T II I
> ----- ---------- ----------
> M 7000,77 49
> K 17000,17 59

> The Output which I would like to see is
 

> M 0700077049
> K 1700017059

> I tried:
 

> SET NEWPAGE 0
> SET SPACE 0
> SET PAGESIZE 0
> SET ECHO OFF
> SET FEEDBACK OFF
> SET HEADING OFF
> column i format 000
> column ii format 00000v00
 

> and the result is
 

> M 0700077 049
> K 1700017 059
 

> There is one extra space before each mumeric value.
 

> How can I avoid this?
 

> TIA.
 
> Manfred
Received on Sun Jun 25 2000 - 00:00:00 CDT

Original text of this message

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