2016-02-26 30 views
0

我使用apache jena sparql api與使用uri的遠程jena fuseki服務器進行通信,如uri:http://localhost:3030/Test。除了選擇,我想sparql插入和刪除查詢。這裏是我的選擇查詢代碼:Jena Fuseki Java中的Sparlql INSERT和DELETE

private String serviceURI = "http://localhost:3030/Test"; 
    /** 
    * This method prints the result of a sparql query as table 
    * @param Query to get the result of 
    */ 
    public void printSparqlResult(String query){ 
     QueryExecution q = QueryExecutionFactory.sparqlService(this.serviceURI,query); 
     ResultSet results = q.execSelect(); // get result-set 
     ResultSetFormatter.out(System.out, results); // print results 
    } 

回答

相關問題