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

Home -> Community -> Usenet -> c.d.o.misc -> Re: How to handle newlines in files via PL/SQL

Re: How to handle newlines in files via PL/SQL

From: Rauf Sarwar <rsarwar_at_ifsna.com>
Date: 27 Jun 2002 19:25:00 -0700
Message-ID: <c2d690f2.0206271825.1c3ecd0b@posting.google.com>


"Koez" <jani.mannisto_at_nettaxi.com> wrote in message news:<eoCS8.146$8d7.5407_at_read2.inet.fi>...
> Hi, I need help with the followin procedure:
>
> Procedure TEST
> IS
> file_in UTL_FILE.FILE_TYPE;
> BEGIN
> file_in := UTL_FILE.FOPEN ('F:\SAPJ\Files', 'koez.txt', 'W');
> UTL_FILE.PUT (file_in, '1');
> UTL_FILE.PUT (file_in, '11');
> UTL_FILE.NEW_LINE (file_in);
> UTL_FILE.PUT (file_in, '2');
> UTL_FILE.FCLOSE(file_in);
> END;
>
> It outputs lines just nicely but I don't want see that last linefeed just
> after letter "2" - what can I do to prevent this
> (I think is has something to do with FCLOSE)??
>
> Output:
>
> row 1: 111
> row 2: 2
> row 3:
>
>
> !jani

I believe FCLOSE adds a standard EOL if one not already there. Received on Thu Jun 27 2002 - 21:25:00 CDT

Original text of this message

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