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: File transfer through the database

Re: File transfer through the database

From: Frank van Bortel <frank.van.bortel_at_gmail.com>
Date: Sat, 24 Dec 2005 12:33:35 +0100
Message-ID: <dojb29$ho2$1@news5.zwoll1.ov.home.nl>


Eric de Redelijkheid wrote:
> Hello,
>
> Oracle 9iR2 Enterprise edition on Tru64 5.1B
>
> We currently have a database application that creates RTF-documents on
> an UNIX-directory. For Windows-clients to read those documents, we have
> to transfer these files, either by ftp or, as I currently do, by HTTP
> (Internet Explorer starts with MS-WORD; the document is loaded). We do
> this in a single script with the document name as parameter.
>
> The HTTP-server is a different machine, wich has to be retired from
> service, so I would like a different option.
>
> I am thinking of two possibilities:
>
> 1. load the file line by line in a table with UTL_FILE, spool those
> lines to a RTF-file on a Windows directory and load this file in Word.
> 2. insert a pointer to this file in a BFILE column in a table,
> dowload this file to Windows and start Word.
>
> The first seems straightforward, but only works for textfiles and I
> don't get the entire file at once. I'd rather have something more generic.
>
> I don't know how to get about the second option. I can create the table.
> When using TOAD, I can doubleclick on a field in that BFILE column and a
> Window appears asking me if I want to run the associated program. The
> document is then loaded in MS Word.
>
> Since normal users do not have TOAD, I need another way to run a single
> script with only the document name as parameter, which does the trick
> for me. I am not a programmer, but a DBA. What do I use best? PL/SQL,
> Java, Forms? Has anyone got example-code?
>
> I do not have the possibility to install any additional software on the
> clients. They normally access the database using Forms 6.

Don't generate the documents to an external directory, but feed them to the client directly, using an ms-word mime type. Or define the directory used as an Oracle directory, and use external tables; I'd think a line does not exceed 4k characters, so varchar2 should do the trick. Less intrusive on the application: the files are still where they used to be.
Performance on external tables is quite acceptable - I've used this for Dutch Postal codes verification.

-- 
Regards,
Frank van Bortel

Top-posting is one way to shut me up...
Received on Sat Dec 24 2005 - 05:33:35 CST

Original text of this message

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