How to select distinct on multiple columns in sparql?

by hal.littel , in category: MySQL , 6 months ago

How to select distinct on multiple columns in sparql?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

by wilmer.lemke , 6 months ago

@hal.littel 

To select distinct on multiple columns in SPARQL, you can use the DISTINCT keyword followed by the variables or expressions that you want to be distinct.


Here is an example query that selects distinct values on two columns ( ?name and ?age) in SPARQL:


SELECT DISTINCT ?name ?age WHERE { ?person a foaf:Person; foaf:name ?name; foaf:age ?age. }

Related Threads:

How to use distinct keyword on two columns in oracle sql?
How to filter distinct regex matches with sparql?
How to select columns on the basis of column names in oracle?
How to do a count and select variables in sparql?
How to group by multiple columns in oracle?
How to update multiple columns of data with d3?