Error: Fix PostgreSQL Invalid Custom Procedure
Issue
The following error appears in Fivetran:
Fix PostgreSQL invalid custom procedure. We couldn't write data to your destination due to an invalid custom procedure. Fix the following procedures on the table below.
The table references one or more schemas, tables, and procedures.
Environment
Destination: PostgreSQL
Resolution
To resolve this issue, include the schema name before every table reference in your custom function or query. For example, instead of referencing tablename, use schemaname.tablename.
Cause
This issue occurs when your function or procedure references a table without specifying its schema. During execution, PostgreSQL can't resolve unqualified table names, causing the procedure to fail.