Ignore AFTER triggers sorting after z_repack_trigger

They are not a problem, and they fore after the BEFORE trigger anyway.

To be checked against more PostgreSQL versions.
This commit is contained in:
Daniele Varrazzo
2013-04-17 19:10:24 +01:00
parent 22762fce28
commit 477fba884c
3 changed files with 46 additions and 0 deletions

View File

@ -219,6 +219,7 @@ CREATE FUNCTION repack.conflicted_triggers(oid) RETURNS SETOF name AS
$$
SELECT tgname FROM pg_trigger
WHERE tgrelid = $1 AND tgname >= 'z_repack_trigger'
AND (tgtype & 2) = 2 -- BEFORE trigger
ORDER BY tgname;
$$
LANGUAGE sql STABLE STRICT;