oracle 10gR2 not provisoned for RDF support
617912Jan 29 2008 — edited Jan 29 2008Hello All,
I am working on loading some RDF models into ORACLE 10gR2 database. I have applied the JenaAdapter patch ( downloaded from the OTN ) to the database. The patch is successful(there are no errors while applying patch).BUT
When we are trying to run this sample program :
package example;
import java.sql.SQLException;
import com.hp.hpl.jena.graph.Node;
import com.hp.hpl.jena.graph.Triple;
import com.hp.hpl.jena.util.iterator.ExtendedIterator;
import oracle.spatial.rdf.client.jena.GraphOracleSem;
import oracle.spatial.rdf.client.jena.Oracle;
public class Sample {
/**
* @param args
* @throws SQLException
*/
public static void main(String[] args) throws SQLException {
String jdbcUrl = "jdbc:oracle:thin:@10.176.94.90:1521:oracle";
String user = "mdsys";
String password = "oracle";
String modelName = "haha";
Oracle oracle = new Oracle(jdbcUrl, user, password);
GraphOracleSem graph = new GraphOracleSem(oracle, modelName);
Node sub = Node.createURI("http://test/s");
Node pred = Node.createURI("http://test/p");
Node obj = Node.createURI("http://test/o");
Triple triple1 = Triple.create(sub, pred, obj);
graph.add(triple1);
ExtendedIterator it = graph.find(Triple.ANY);
while (it.hasNext()) {
Triple t = (Triple) it.next();
System.out.println("Triple = " + t.toString());
}
graph.close();
oracle.dispose();
}
}
It is giving the following error:
Exception in thread "main" java.lang.IllegalStateException: This database is not provisioned for RDF. Oracle requires that a DBA provision the database for RDF support.
at oracle.spatial.rdf.client.jena.GraphOracleSem.<init>(GraphOracleSem.java:732)
at oracle.spatial.rdf.client.jena.GraphOracleSem.<init>(GraphOracleSem.java:493)
at oracle.spatial.rdf.client.jena.GraphOracleSem.<init>(GraphOracleSem.java:403)
at example.Sample.main(Sample.java:25)
Please help me through this................
-------Rajesh