Mbaroudi / puelia-php

Automatically exported from code.google.com/p/puelia-php
0 stars 0 forks source link

Property path query construction is incorrect #39

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using the attached config file, access:

  http://localhost/transport/doc/bus-stop-point?administrativeArea.region.country.countryCode=Wales&_properties=administrativeArea.region.country.countryCode

This should give only bus stops in Wales. However, the query that's generated 
is:

SELECT DISTINCT ?item
WHERE 
{
  ?item <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> 
    <http://transport.data.gov.uk/def/naptan/BusStopPoint> . 
  ?item <http://transport.data.gov.uk/def/naptan/administrativeArea> ?administrativeArea . 
  ?administrativeArea <http://transport.data.gov.uk/def/naptan/region> 
    ?administrativeArea_region .  
  ?region <http://transport.data.gov.uk/def/naptan/country> ?region_country .  
  ?country <http://transport.data.gov.uk/def/naptan/countryCode> 
    """Wales"""^^<http://transport.data.gov.uk/def/naptan/CountryCode> .
} 

Note that the object of the third clause is ?administrativeArea_region, whereas 
the subject of the fourth clause is ?region. Similarly, the object of the 
fourth clause is ?region_country whereas the subject of the fifth clase is 
?country. This therefore returns all bus stops if there is a country in the 
triplestore with the code 'Wales', rather than just those within Wales.

Original issue reported on code.google.com by jeni.ten...@gmail.com on 12 Jul 2010 at 6:44

Attachments:

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r102.

Original comment by K.J.W.Al...@gmail.com on 16 Jul 2010 at 3:08