I\'m trying to write a function in PL/PgSQL that have to work with a table it receives as a parameter.
I use EXECUTE..INTO..USING statements within the function def
$1 should be inside the || ,like || $1 || and give spaces properly then it will work.
$1
||
|| $1 ||
BEGIN EXECUTE ' delete from ' || quote_ident($1) || ' where condition '; END;