HINT: No function matches the given name and argument types. You may need to add explicit type casts.
CREATE OR REPLACE FUNCTION "public"."fc_editlanguage" (id bigint, name varchar, kuerzel varchar, active smallint) RETURNS smallint AS
$body$
DECLARE id bigint;
DECLARE varlanguage varchar(60);
DECLARE browsershortcut varchar(10);
DECLARE insertdate date;
DECLARE active smallint;
DECLARE varreturn smallint;
Begin
varreturn := 0;
id := $1;
varlanguage := cast($2 as varchar(60));
bowsershortcut := cast($3 as varchar(10));
active := $4;
if(id=0) then
insertdate := now();
INSERT INTO tbl_language (la_language, la_browsershortcut, la_insertdate, la_active)
VALUES
(varlanguage, browsershortcut, insertdate, active);
else
UPDATE tbl_language SET la_language=varlanguage, la_browsershortcut=browsershortcut, la_active=active
WHERE la_id = id;
end if;
return varreturn;
end;
$body$
LANGUAGE 'plpgsql' VOLATILE CALLED ON NULL INPUT SECURITY INVOKER;
Greetings from Germany,