Search code examples
sqlnode.jspostgresqlvertica

sql round function throw error - Schema "pg_catalog" does not exist


I'm querying Vertica using node-vertica npm packge (Node server), I noticed that every time the ROUND expression is 0/null, I'm getting the error - ERROR: Schema "pg_catalog" does not exist.

EDIT:

For example:

SELECT 
  name,
  email,
  ROUND(SUM(grade)/nullifzero(count(grade))) as avrage ----> ROUND(0/null)
FROM il_grades
GROUP BY name,email
LIMIT 10

Return this error. Once I remove the ROUND() - everything is working properly.


Solution

  • The vertica-client package was the issue (unmaintained) , after I removed it and install the official Vertica's vertica-nodejs node pkg it works as expected!