SPARQL Query Example 1 in web ontology

learning sparql

Resource description freamework(RDF):

learning sparql

SPARQL Query:

PREFIX ab: <https://www.t4tutorials.com/personal#>
SELECT ?name
WHERE
{
?person ab:firstName “barak” .
?person ab:lastName “obama” .
?p
  • ?name is a variable any name can be in this variable
  • ?person is the subject and
  • firstName is the predicate
  • lastName is the predicate
  • barak is the object
  • obama is the object

Output:

name
barak obama

 

 

 

 

By:Prof. Fazal Rehman Shamil
CEO @ T4Tutorials
Last Modified: May 27, 2019

Leave a Reply

Your email address will not be published. Required fields are marked *