utl_file with server 7.3.4

utl_file with server 7.3.4

Post by Dirk Mik » Fri, 08 Jun 2001 21:40:37



Hi,

we're using oracle 7.3.4 and i try to use utl_file within a pl/sql
procedure to write to a file. But because you just can use a 1023 byte
buffer at "put_line" i tried to split a larger lines into 1023
byteblocks and use "put" to write it. But i get a "write error"
exception everytime a line is larger than 1023 bytes. Even if i use
"put" to write it byte by byte.
Is there any way to write a line to a file which is longer than 1023
bytes?

Regards
Dirk Mika

 
 
 

utl_file with server 7.3.4

Post by Thomas Kyt » Sat, 09 Jun 2001 04:29:15



(if that email address didn't require changing)


>Hi,

>we're using oracle 7.3.4 and i try to use utl_file within a pl/sql
>procedure to write to a file. But because you just can use a 1023 byte
>buffer at "put_line" i tried to split a larger lines into 1023
>byteblocks and use "put" to write it. But i get a "write error"
>exception everytime a line is larger than 1023 bytes. Even if i use
>"put" to write it byte by byte.
>Is there any way to write a line to a file which is longer than 1023
>bytes?

>Regards
>Dirk Mika

prior to Oracle 8.0.5 (which introduced the 4th parameter to fopen) -- no there
is not.
--

Howtos and such: http://asktom.oracle.com/ http://asktom.oracle.com/~tkyte/
Oracle Magazine: http://www.oracle.com/oramag
Opinions are mine and do not necessarily reflect those of Oracle Corp

 
 
 

1. UTL_FILE and UTL_FILE.FILE_TYPE

Hi,
   Does anyone know of a way to store the filehandle returned value from
UTL_FILE.FOPEN in a PL/SQL table ?

eg.

          type file_details is record
               (disp_pipe_id varchar2(20),
                disp_file_id utl_file.file_type);   <<<<=============
doesn't seem to like this bit ?!?!

          type tab_file_details is table of file_details
               index by binary_integer;

          rec_file_detail    tab_file_details;

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

   if rec_file_detail(rec_counter).disp_pipe_id = returnpipe then
        file_id := rec_file_detail(rec_counter).disp_file_id;
        file_open := utl_file.is_open(file_id);
        if file_open then
            anyerrors := 'File already open';
            exit ;
        end if;
    end if;

Sorry if it's a stupid question

Thanks in advance if it's not

Ian

--

or remove extra m in downham

2. Lottery Information

3. UTL_FILE how to use utl_file.get_line

4. Group by

5. UTL_FILE Package, only server side ???

6. Invalid Class String error when calling VB component

7. UTL_FILE package for Oracle 7.2.2.4.0 Server

8. Is CompactDatabase broken? Jet 4.0 vs MSAcess 2000

9. UTL_FILE : Is it possible to use utl_file through network path ?

10. Q: Solution for bug 458336? (UTL_FILE.PUT() -> UTL_FILE.WRITE_ERROR)

11. UTL_FILE-Equivalency

12. Help using UTL_FILE in Oracle stored procs