-
as seen on Stack Overflow
- Search for 'Stack Overflow'
i'm new to jena and protege.i did some stuff with these. i have some problems::
1) Do i need to use sparql query to get the ontology classes,subclasses,property and values? or can do it with owl-api? can u show me the way?
2) how to get the data property values?
3) how to i load the ontology that…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
InfModel infmodel = ModelFactory.createInfModel(reasoner, m);
Resource vegetarian = infmodel.getResource(source + "Vegetarian");
Resource margherita = infmodel.getResource(source + "Example-Margherita");
if (infmodel.contains(margherita, RDF., vegetarian)) {
System.out.println("Margherita…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
How can I get in Jena (Java language) result in UTF-8 format?
My code:
Query query= QueryFactory.create(queryString);
QueryExecution qexec= QueryExecutionFactory.sparqlService("http://lod.openlinksw.com/sparql", queryString);
ResultSet results = qexec.execSelect();
List<QuerySolution> list =…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I am trying sparql and the use of entailment.
As a example i used http://www.w3.org/TR/2010/WD-sparql11-entailment-20100126/#t112
i try to put them in jena.
OntClass book1= model.createClass(NS+"book1");
OntClass book2=model.createClass(NS+"book2");
OntClass book3=model.createClass(NS+"book3");
…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Hi,
I have an ontology, which I read in with Jena to help me scrape some RDFa triples from a website. I don't currently store these triples in a Jena model, but that is fairly straight forward to do, its on my to do next list.
The area I am struggling with, though, is to get Jena to output correct…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I have done a lot of searching about this topic through Google but I have yet to find someone using getString() in the way that I am using it so I have not been able to fix this issue in the normal ways that are suggested.
What I am trying to do is to obtain all of the information from the database…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Hi, I have a stored procedure in an Oracle 10g database, in my java code, i call it with:
CallableStatement cs = bdr.prepareCall("Begin ADMBAS01.pck_basilea_reportes.cargar_reporte(?,?,?,?,?); END;", ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_READ_ONLY);
cs.setInt(1, this.reportNumber);
…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Hello
Does anyone know a better way of getting the number of rows in a Java resultset returned from a MySQL database?
I'm currently using this:
public static int getResultSetRowCount(ResultSet resultSet) {
int size = 0;
try {
resultSet.last();
size = resultSet.getRow();
…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
package collabsoft.backlog_reports.c4;
import java.sql.CallableStatement;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.Statement;
//import collabsoft.backlog_reports.c4.Report;
public class Report {
private…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
package collabsoft.backlog_reports.c4;
import java.sql.CallableStatement;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.Statement;
//import collabsoft.backlog_reports.c4.Report;
public class Report {
private…
>>> More