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 -> Acessing .properties file after loading into db as JAVA RESOURCE

Acessing .properties file after loading into db as JAVA RESOURCE

From: Maury Jarrell <mj_at_mauryjarrell.com>
Date: 24 Apr 2003 07:29:44 -0700
Message-ID: <67c512fc.0304240629.185b86b@posting.google.com>


I have loaded a properties file into the database using loadjava. I have verified that it exists as a JAVA RESOURCE, but I can't figure out how to access it.

I have tried:

public class TestProps {

  public static void main(String[] args) throws Exception {                                 

    FileInputStream fin = new FileInputStream( "Hola.properties" );     Properties hola = new Properties();
    hola.load(fin);
    hola.list(System.out);
  }
}

When I load this class in the database, create a call spec and then run it, I get:

ORA-29532: Java call terminated by uncaught Java exception: java.lang.SecurityException: relative pathnames are not allowed(Hola.properties)

I've tried to put a slash in front, but get a FileNotFound exception. I'm sure that I'm going about this the wrong way, but I have scoured Oracle docs, newgroups, and web sites looking for how to do this to no avail. Any help would be appreciated.

Thanks,
Maury Jarrell Received on Thu Apr 24 2003 - 09:29:44 CDT

Original text of this message

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