我使用的是属性路径,我使用的是AllegroGraph Server Edition 4.9。我创建了一个sparql查询,
select ?y ?x (count(?x) as ?degree)
where{
{
?x $path ?y.
filter(match($path,foaf:knows))
filter(pathLength($path) <= 3)
}
UNION
{
?y $path ?x.
filter(match($path,foaf:knows))
filter(pathLength($path) <= 3)
}
} group by ?y ?x.我希望看到与foaf的最大3度相关性:knows property。但是它给了我匹配,并且pathLength函数不被识别。我认为这是一个等价图问题。或者可能我的查询是错误的。有没有人尝试过pathLengh和match函数?
谢谢
ğdaş的圣杯
发布于 2013-03-27 15:47:57
SPARQL1.1不包括match和pathLength函数。This是属性路径的引用。所以这是我的错。希望在未来的sparql版本中看到这些特性。
https://stackoverflow.com/questions/15637309
复制相似问题