简体   繁体   中英

Sending SPARQL queries to Fuseki

I have queries like this.

SELECT * WHERE{
  SERVICE <endpoint 1>{
    SELECT ?country ?port
    WHERE {?port <country> ?country}
  }
  SERVICE <endpoint 2>{
    SELECT ?ship ?name ?country
    WHERE {?ship <flagoftheship> ?country.
      ?ship <vesselname> ?name
    }
  }
}

and i'm developing a frontend to send queries like that (can have several endpoints, the user may even provide it's own endpoint URL) to a Fuseki Server, i've been using the Fuseki frontend that hosts over port 3030 when you run the Server but i want to know how can i actually send those queries from my own app, do i need to execute a cmd command? (using a server that receives the query from the javascript app and then runs the command)

EDIT: pretty much i need to know what does the Fuseki frontend when you click the "play" button so that the server gets the query that you put in the textbox

Fuseki implements the SPARQL 1.1 Protocol which gives several ways of submitting a query to a SPARQL endpoint. The simplest is probably the HTTP GET with the query url-encoded as a parameter named query .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM