使用最新的稳定版本:Linux上的Virtuoso版本07.20.3215(x86_64-unknown-linux-gnu)。
我对自定义N3序列化RDF数据集的初始SPARQL查询是:
select (?s as ?addr),
?geo,
(bif:st_distance (?geo, bif:st_point(51.3, 12.3)) as ?dist)
where
{
?s <http://www.opengis.net/ont/geosparql#asWKT> ?geo .
?s <http://location/class> "place" .
?s <http://location/type> "house" .
}
并且它给出了期望的结果:
<table class="sparql" border="1">
<tr>
<th>addr</th>
<th>geo</th>
<th>dist</th>
</tr>
<tr>
<td><a href="addr1">addr1</a></td>
<td>"POINT(51.345624 12.3918959)"^^<http://www.openlinksw.com/schemas/virtrdf#Geometry></td>
<td>11.3504</td>
</tr>
</table>
&#13;
虽然当我为FILTER
添加bif:st_intersects
语句时,使用以下查询:
select (?s as ?addr),
?geo,
(bif:st_distance (?geo, bif:st_point(51.3, 12.3)) as ?dist)
where
{
?s <http://www.opengis.net/ont/geosparql#asWKT> ?geo .
?s <http://location/class> "place" .
?s <http://location/type> "house" .
FILTER (bif:st_intersects (?geo, bif:st_point (51.3, 12.3), 100))
}
它给出了一条错误消息No table rdf_obj
Virtuoso S0002 Error SQ200: No table rdf_obj
SPARQL query:
define sql:big-data-const 0
#output-format:text/html
define sql:signal-void-variables 1 define input:default-graph-uri <http://localhost:8890/custom1> select (?s as ?addr), ?geo, (bif:st_distance (?geo, bif:st_point(51.3, 12.3)) as ?dist)
where
{
?s <http://www.opengis.net/ont/geosparql#asWKT> ?geo .
?s <http://location/class> "place" .
?s <http://location/type> "house" .
FILTER (bif:st_intersects (?geo, bif:st_point (51.3, 12.3), 100))
}
为什么会发生这种情况,是否有解决方法?