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: DIRECTORIES and BFILE problems

Re: DIRECTORIES and BFILE problems

From: Rauf Sarwar <rs_arwar_at_hotmail.com>
Date: 2 Mar 2005 15:03:35 -0800
Message-ID: <1109804615.440413.312640@g14g2000cwa.googlegroups.com>

JavaDeveloper wrote:
> Hi all!
> I'm having a problem in creating BFILEs in a DB directory.
>
> In my Java program I do these simple steps.
>
> 1. Create a directory:
>
> CREATE OR REPLACE TEMP_DIR AS 'D:\\FILES'
>
> The double \ is for java string processing purpose. It doesn't affect
the
> creation of the directory.
>
> 2. Pass a file in the DB directory (the file name is "binaryfile.dat"
and is
> in the D:\\FILES directory on the file system):
>
> INSERT INTO MYTABLE (BFILE_COLUMN)
> VALUES ( bfilename ('TEMP_DIR', 'binaryfile.dat'))
>
> After these steps, controlling the table with a graphical DB tool
(i.e.
> Toad), I see that in the BFILE column, after the name of the file
loaded,
> there is a notice like "NoExist".
> Reading that BFILE in my Java program, I find out that the file
length is 73
> bytes instead of 40 Kb!!!
> The file does not exist!!!
> My question is... why???
>
> Note: Le DB is not in my computer, but the file binaryfile.dat is my
local
> file system. Maybe, the loading works only on the same file system of
the
> DB?? I hope not! :-)
>
> Thanks
>
> Matt

Directory object is relative to the server where the database is running... NOT the client.

Regards
/Rauf Received on Wed Mar 02 2005 - 17:03:35 CST

Original text of this message

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