Virtuoso 中用户定义的 SPARQL 聚合函数

User-defined SPARQL aggregation functions in Virtuoso

我想在 SPARQL 中实现一个用户定义的布尔聚合函数,我正在检查 easy/feasible 在不同的 SPARQL 引擎中是否如此。关于Virtuoso,可能吗?如果是这样,我在哪里可以找到有关它的更多信息?通过谷歌搜索,我找到了如何针对 SQL 而不是 SPARQL:http://docs.openlinksw.com/virtuoso/aggregates/

感谢您的关注和帮助, 路易斯

你已经完成一半了。

Virtuoso 允许您在 SPARQL 查询中使用 SQL 函数,包括内置 (bif:) 和用户定义 (sql:),如 discussed in the documentation

A SPARQL expression can contain calls to Virtuoso/PL functions and built-in SQL functions in both the WHERE clause and in the result set. Two namespace prefixes, bif and sql are reserved for these purposes. When a function name starts with the bif: namespace prefix, the rest of the name is treated as the name of a SQL BIF (Built-In Function). When a function name starts with the sql: namespace prefix, the rest of the name is treated as the name of a Virtuoso/PL function owned by DBA with database qualifier DB, e.g., sql:example(...) is converted into DB.DBA."example"(...).

ObDisclaimer:OpenLink Software produces Virtuoso,并雇用了我。