Not logged in : Login

About: VirtTipsAndTricksSPARQL11BIND     Goto   Sponge   NotDistinct   Permalink

An Entity of Type : atom:Entry, within Data Space : ods.openlinksw.com associated with source document(s)

AttributesValues
type
Date Created
Date Modified
label
  • VirtTipsAndTricksSPARQL11BIND
maker
Title
  • VirtTipsAndTricksSPARQL11BIND
isDescribedUsing
has creator
content
  • %META:TOPICPARENT{name="VirtTipsAndTricksSPARQL11FeaturesExamplesCollection"}% ---+Virtuoso SPARQL 1.1. BIND Usage Examples ---++What? This guide contains Virtuoso SPARQL 1.1. BIND Usage example queries which you can run against any SPARQL endpoint that supports SPARQL 1.1 and the ability to allow a verified user perform INSERT operations. ---++Why? To make a SPARQL query more flexible by assigning value(s) to variable(s) and having options for more precised filtering the query results by these variables. ---++How? 1 Assume the following Raw Data Representation in Turtle: <verbatim> @prefix: <http://example.org/book/> . @prefix ns: <http://example.org/ns#> . :book1 <http://purl.org/dc/elements/1.1/title> "SPARQL Tutorial" . :book1 ns:price 42 . :book1 ns:discount 0.2 . :book2 <http://purl.org/dc/elements/1.1/title> "The Semantic Web" . :book2 ns:price 23 . :book2 ns:discount 0.25 . </verbatim> 1 Load the sample data: <verbatim> PREFIX : <http://example.org/book/> PREFIX ns: <http://example.org/ns#> INSERT { GRAPH <urn:sparql:bind:tests> { :book1 <http://purl.org/dc/elements/1.1/title> "SPARQL Tutorial" . :book1 ns:price 42 . :book1 ns:discount 0.2 . :book2 <http://purl.org/dc/elements/1.1/title> "The Semantic Web" . :book2 ns:price 23 . :book2 ns:discount 0.25 . } } </verbatim> 1 Assume the following SPARQL query using <code>BIND</code>: <verbatim> PREFIX ns: <http://example.org/ns#> SELECT ?title ?price FROM <urn:sparql:bind:tests> { ?x ns:price ?p . ?x ns:discount ?discount . ?x <http://purl.org/dc/elements/1.1/title> ?title . BIND (?p*(1-?discount) AS ?price) FILTER( ?price < 20 ) } </verbatim> 1 [[http://bit.ly/18Whdgh][View the SPARQL Query Definition via SPARQL Protocol URL]] 1 [[http://bit.ly/18WhbVR][View the SPARQL Query Results via SPARQL Protocol URL]] ---++Related * [[VirtTipsAndTricksGuide][Virtuoso Tips and Tricks Collection]] * [[VirtTipsAndTricksSPARQL11FeaturesExamplesCollection][Virtuoso SPARQL 1.1 Usage Examples Collection]] * [[http://virtuoso.openlinksw.com/tutorials/sparql/SPARQL_Tutorials_Part_9/SPARQL_Tutorials_Part_9.html][Virtuoso SPARQL 1.1 Syntax Tutorial]] * [[http://bit.ly/WHtTAG][Virtuoso SPARQL 1.1. BIND Tutorial]] * [[http://docs.openlinksw.com/virtuoso/rdfsparql.html][Virtuoso Documentation]]
id
  • 428140e6d9456d2e6a4d5a5576989f7f
link
has container
http://rdfs.org/si...ices#has_services
atom:title
  • VirtTipsAndTricksSPARQL11BIND
links to
atom:source
atom:author
atom:published
  • 2017-06-13T05:46:52Z
atom:updated
  • 2017-06-13T05:46:52Z
topic
is made of
is container of of
is link of
is http://rdfs.org/si...vices#services_of of
is creator of of
is atom:entry of
is atom:contains of
Faceted Search & Find service v1.17_git150 as of Jan 20 2025


Alternative Linked Data Documents: iSPARQL | ODE     Content Formats:   [cxml] [csv]     RDF   [text] [turtle] [ld+json] [rdf+json] [rdf+xml]     ODATA   [atom+xml] [odata+json]     Microdata   [microdata+json] [html]    About   
This material is Open Knowledge   W3C Semantic Web Technology [RDF Data] Valid XHTML + RDFa
OpenLink Virtuoso version 08.03.3332 as of Sep 11 2024, on Linux (x86_64-generic-linux-glibc25), Single-Server Edition (15 GB total memory, 759 MB memory in use)
Data on this page belongs to its respective rights holders.
Virtuoso Faceted Browser Copyright © 2009-2025 OpenLink Software