Your SlideShare is downloading. ×
0
Sparql
Sparql
Sparql
Sparql
Sparql
Sparql
Sparql
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Sparql

834

Published on

Published in: Technology, Design
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
834
On Slideshare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
14
Comments
0
Likes
1
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. SPARQL Query!Group: Qian, Pierre-Adrien
  • 2. Query 1Objective: Find all the people who were born in Paris on DBpediaPREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX : <http://dbpedia.org/resource/>PREFIX dbpedia2: <http://dbpedia.org/property/>PREFIX dbpedia: <http://dbpedia.org/>PREFIX dbpedia3: <http://dbpedia.org/ontology/>SELECT distinct ?name ?birth ?person WHERE { ?person dbpedia2:birthPlace <http://dbpedia.org/resource/Paris> . ?person dbpedia2:birthDate ?birth . ?person foaf:name ?name .} ORDER BY ?nameResult:Plenty of them!ex: "René Laloux"@en1929-07-13http://dbpedia.org/resource/Ren%C3%A9_Laloux
  • 3. Query 2Objective: Find all the people born in Paris after 1970 by using FILTERPREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX dbpedia: <http://dbpedia.org/>PREFIX dbpedia2: <http://dbpedia.org/property/>PREFIX dbpedia3: <http://dbpedia.org/ontology/>SELECT distinct ?name ?person ?birthDate WHERE { ?person dbpedia2:birthPlace <http://dbpedia.org/resource/Paris> . ?person foaf:name ?name . ?person dbpedia2:birthDate ?birthDate . FILTER (1970 < ?birthDate)} ORDER BY ?birthDateResult:"Jules de Balincourt"@enhttp://dbpedia.org/resource/Jules_de_Balincourt"1972"^^<http://www.w3.org/2001/XMLSchema#int>"Phoebe Philo"@enhttp://dbpedia.org/resource/Phoebe_Philo"1973"^^<http://www.w3.org/2001/XMLSchema#int>"Caroline Ducey"@enhttp://dbpedia.org/resource/Caroline_Ducey"1977"^^<http://www.w3.org/2001/XMLSchema#int>
  • 4. Query 3Objective: Find all the solo singer who were born in LondonPREFIX dbpedia3: <http://dbpedia.org/ontology/>SELECT distinct ?name ?birthdate ?person WHERE{ ?person dbpedia3:birthPlace <http://dbpedia.org/resource/London> . ?person dbpedia3:birthDate ?birthdate . ?person dbpedia3:background "solo_singer"@en . ?person foaf:name ?name .} ORDER BY ?name
  • 5. Query 4Objective: Find all the people born in Brest using FILTER regexPREFIX foaf: <http://xmlns.com/foaf/0.1/>PREFIX dbpedia2: <http://dbpedia.org/property/>PREFIX dbpedia: <http://dbpedia.org/>PREFIX dbpedia3: <http://dbpedia.org/ontology/>SELECT distinct ?name ?person ?birthPlace WHERE { ?person foaf:name ?name . ?person dbpedia2:birthPlace ?birthPlace FILTER regex (?birthPlace, "Brest")} ORDER BY ?nameResult :"Alex Thepot"@enhttp://dbpedia.org/resource/Alex_Th%C3%A9pothttp://dbpedia.org/resource/Brest,_Finist%C3%A8re"Alex Thépot"@enhttp://dbpedia.org/resource/Alex_Th%C3%A9pothttp://dbpedia.org/resource/Brest,_Finist%C3%A8re"Alexand re Coeff"@enhttp://dbpedia.org/resource/Alexandre_Coeffhttp://dbpedia.org/resource/Brest,_Finist%C3%A8re"Alexis Thépot"@enhttp://dbpedia.org/resource/Alex_Th%C3%A9pothttp://dbpedia.org/resource/Brest,_Finist%C3%A8re
  • 6. Query 5Objective: Find the solo artists who did concert tours of more than 200 showsPREFIX dbpedia2: <http://dbpedia.org/property/>SELECT distinct ?tour ?artist ?numberOfShows WHERE{ ?tour dbpedia2:artist ?artist . ?artist dbpedia2:background "solo_singer"@en . ?tour dbpedia2:numberOfShows ?numberOfShows . FILTER (?numberOfShows > 200)} ORDER BY ?numberOfShowsSeveral results (Bob Dylan, Cher, Lady Gaga...)
  • 7. Query Simpsons• Find out all the chalk gag that Bart wrote on the blackboard! – http://www.snee.com/bobdc.blog/2008/10/learning-more-about-sparql.html – http://www.snee.com/bobdc.blog/2007/11/querying-dbpedia.html – http://dbpedia.org/page/Category:The_Simpsons_episodes• We didn’t succeed in doing this within our limited working hours. So if you are interested, try it out! These links are useful for you!

×