Virtuoso Open-Source Wiki
Virtuoso Open-Source, OpenLink Data Spaces, and OpenLink Ajax Toolkit
Advanced Search
Help?
Location: / Dashboard / Main / NorthWindREFExample9

Dump all OrderLines including order date timestamps accurate to the second (as opposed to millisecond) and quantity expression.

prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
prefix ndw:<http://demo.openlinksw.com/schemas/northwind#>
prefix xsd: <http://www.w3.org/2001/XMLSchema#>
select ?o_date ?p_name ?o_uprice ?quantity ?discount
where
  { 
    ?ol rdf:type ndw:OrderLine .
    ?ol ndw:has_order_id ?oid .
    ?oid rdf:type ndw:Order .
    ?oid ndw:orderDate ?o_date .
    ?ol ndw:has_product_id ?pid .
    ?pid rdf:type ndw:Product .
    ?pid ndw:productName ?p_name . 
    ?ol ndw:unitPrice ?o_uprice.
    ?ol ndw:quantity ?quantity.
    ?ol ndw:discount ?discount.
    filter (xsd:integer(?quantity) > xsd:integer("15")) .
    filter (xsd:dateTime (?o_date) > xsd:dateTime  ("1996-01-01T10:00:00Z")) .   
  }
Sample Data (Live Query Results)
  • Click *Here* for a live SPARQL Query (via SPARQL Protocol) against a collection of Northwind OrderLines.
Powered By Virtuoso