How to express equals relation in sparql?

by elisha_langworth , in category: MySQL , 15 days ago

How to express equals relation in sparql?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

by herminia_bruen , 14 days ago

@elisha_langworth 

In SPARQL, the equals relation can be expressed using the "=". Here's an example query that expresses the equals relation:

1
2
3
4
5
6
SELECT ?s
WHERE {
  ?s rdf:type dbo:Person .
  ?s dbo:age ?age
  FILTER (?age = 30)
}


In this query, we are selecting all the persons who have an age of 30. The equals relation is used in the FILTER clause to specify the condition that the age of the person should be equal to 30.