age-website
age-website copied to clipboard
Issues on the user defined functions query
The following example is not working properly which is at https://age.apache.org/age-manual/master/functions/user_functions.html It has multiple issues:
- Missing ')' closing parentheses
- Missing typecasting
- Result is incorrect (sqrt(25) is 5 while the result is mentioned as 25)
Test environment:
PG: 11 AGE: 1.2.0 OS: Ubuntu 18
The output after having getting the closing parentheses fixed:
rrr=# SELECT *
rrr-# FROM cypher('test', $$
rrr$# RETURN pg_catalog.sqrt(25)
rrr$# $$) as (result agtype);
ERROR: function pg_catalog.sqrt(agtype) does not exist
LINE 3: RETURN pg_catalog.sqrt(25)
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.