Apache AGE (AGE) lets you call functions from any PostgreSQL namespace inside a Cypher query. By default, Cypher resolves all function calls against the ag_catalog namespace, so functions in that namespace need no prefix. To call a function from a different namespace—such as a PostgreSQL built-in or a custom function registered in another schema—prefix the function name with the target namespace.
Syntax
namespace_name.function_nameExample
The following query calls sqrt from the pg_catalog namespace inside a Cypher expression:
SELECT *
FROM cypher('graph_name', $$
RETURN pg_catalog.sqrt(25)
$$) as (result agtype);Output:
result
--------
5.0
(1 row)该文章对您有帮助吗?