Question: I need to know which one has the greater area Sicily or Sardinia (which has an ISO 3166-2 code is IT-88)
Choices:
Piedmont
Abruzzo
Apulia
Basilicata
Veneto
Tuscany
Lombardy
Friuli–Venezia Giulia
Sicily
Lazio
Program:
function: Find
inputs: Sicily
function: Find
inputs: Sardinia
function: FilterStr
dependencies: 1
inputs: ISO 3166-2 code
IT-88
function: SelectBetween
dependencies: 0
2
inputs: area
greater
SPARQL: SELECT ?e WHERE { { ?e <pred:name> "Sicily" . } UNION { ?e <pred:name> "Sardinia" . ?e <ISO_3166-2_code> ?pv_1 . ?pv_1 <pred:value> "IT-88" . } ?e <area> ?pv . ?pv <pred:value> ?v .  } ORDER BY DESC(?v) LIMIT 1
Answer: Sicily