https://bugzilla.wikimedia.org/show_bug.cgi?id=21548
Summary: Disabling triggers in PostgreSQL can only be done by
super user
Product: mwdumper
Version: unspecified
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: Normal
Component: general
AssignedTo: [email protected]
ReportedBy: [email protected]
When restoring a dump of wikipedia into PostgreSQL with mwdump, the first lines
are :
ALTER TABLE revision DISABLE TRIGGER ALL;ALTER TABLE page DISABLE TRIGGER ALL;;
this will result in :
ERROR: permission denied: "RI_ConstraintTrigger_XXXXX" is a system trigger
ERROR: permission denied: "RI_ConstraintTrigger_XXXXX" is a system trigger
because some triggers are managed by the database server itself and cannot be
disabled by any one, except the super user. However there is a way [1] to delay
the constraints applications in order to load a whole bunch of data in the
database and do not need to be super-user :
At the beggining : SET CONSTRAINTS ALL DEFERRED
At the end : SET CONSTRAINTS ALL IMMEDIATE
[1] http://kopongo.com/2008/7/25/postgres-ri_constrainttrigger-error
--
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l