Skip to main content

Missing pltcl function and how to add it (PostgreSQL)

Missing postgresql-contrib-10 and postgresql-pltcl-10 packages

Written by Petr Pech

This issue typically occurs on PostgreSQL versions 10, 9.5, or 9.6 — these are already unsupported versions (see system requirements), so you are most likely running ABRA Flexi on a different version.

Error examples

ERROR: function public.logzurnal() does not exist Kde: SQL statement "ALTER FUNCTION public.logzurnal() OWNER TO dba" PL/pgSQL funkce runupgrade() řádek 17 na SQL příkaz Skript: /resources/sql/upgrade/restore_owners.sql

ERROR: function saveextid() does not exist

(likely to appear when starting the Changes API)

Run the following query and send its output along with the relevant information to podporaflexi@abra.eu (the query must be run directly in the company database as the pgsql admin):

select p.proname, a.rolname from pg_proc p left join pg_language l on p.prolang = l.oid left join pg_authid a on p.proowner = a.oid where l.lanname = 'pltcl';

doplnitPlTclFce.sql - applying this SQL script will resolve the missing function issue

In the line: ALTER FUNCTION invoke_deferred_changes_triggers_immediate() OWNER TO Company role, e.g. "my_companyrole";

Example: ALTER FUNCTION invoke_deferred_changes_triggers_immediate() OWNER TO test_firma_s_r_o_role;

replace Company role, e.g. "my_companyrole" with the actual company role (typically the company name followed by the word "role")

Did this answer your question?