Results 1 to 7 of 7
  1. #1
    Join Date
    Oct 2003
    Posts
    6

    Unanswered: UTL_FILE_DIR invalid path...

    Hi all,

    A classic problem, I've got a Invalid Path Exception when executing:

    v_FileHandle := UTL_FILE.fopen('XML_DIR', 'test.xml', 'r');
    or
    v_FileHandle := UTL_FILE.fopen('e:\plsqlShare', 'test.xml', 'r');


    in my init.ora:
    UTL_FILE_DIR=e:\plsqlShare
    I 've rebooted

    doing also:
    CREATE DIRECTORY XML_DIR AS 'e:\plsqlShare';
    GRANT READ ON DIRECTORY XML_DIR TO PUBLIC;

    on the server directory and file exists...

    Nothing works!!
    please help

  2. #2
    Join Date
    Oct 2003
    Posts
    6
    Correction:

    The modification in the init.ora is not taking into account, i don't know why because i'm doing a shutdown immediate and a restart.
    So I don't understand why... Any Ideas?

  3. #3
    Join Date
    Oct 2003
    Location
    Montreal
    Posts
    10
    Hi,
    which init.ora file did you modify?
    ensure you modify the init<$ORACLE_SID>.ora file

  4. #4
    Join Date
    Oct 2003
    Posts
    6
    Thanks it works now but do you konw if the name resolution for DIRECTORY works with Oracle 9i 9.0.1

    I tried to use the DIRECTORY features:

    CREATE DIRECTORY DIR AS 'e:\directory';
    GRANT READ ON DIRECTORY DIR TO PUBLIC;

    then in pl/sql:

    v_FileHandle := UTL_FILE.fopen('DIR', 'test.txt', 'r');

    raises an invalid path exception....

  5. #5
    Join Date
    Oct 2003
    Location
    Montreal
    Posts
    10
    I'm not too familiar with the DIRECTORY feature nor with 9i , but i fear it may open a security hole

  6. #6
    Join Date
    Oct 2003
    Location
    Switzerland
    Posts
    140
    Originally posted by Goupil
    Thanks it works now but do you konw if the name resolution for DIRECTORY works with Oracle 9i 9.0.1

    I tried to use the DIRECTORY features:

    CREATE DIRECTORY DIR AS 'e:\directory';
    GRANT READ ON DIRECTORY DIR TO PUBLIC;

    then in pl/sql:

    v_FileHandle := UTL_FILE.fopen('DIR', 'test.txt', 'r');

    raises an invalid path exception....
    I had a similar problem once. I executed the command "CREATE DIRECTORY DIR AS 'e:\directory';" on my workstation, and could not write to it (invalid path). Executing the very same command (in an sqlplus) ON THE SERVER solved my problem.

    CVM.

  7. #7
    Join Date
    Oct 2003
    Posts
    6
    Well I tried but it doesn't work

    Anyway thanks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •