Re: [HACKERS] Prettification versus dump safety

2009-11-20 Thread Tom Lane
Andreas Pflug writes: > Tom Lane wrote: >> The easy ways out of this are >> (1) change pg_dump to not prettify trigger definitions at all, or >> (2) change pg_get_triggerdef from the submitted patch so that it >> doesn't reduce parenthesization even in "pretty" mode. >> > The pretty option was ex

Re: [HACKERS] Prettification versus dump safety

2009-11-20 Thread Andreas Pflug
Tom Lane wrote: In testing the TRIGGER WHEN patch, I notice that pg_dump is relying on pg_get_triggerdef(triggeroid, true) (ie, "pretty" mode) to dump triggers. This means that trigger WHEN conditions will be dumped without adequate parenthesization to ensure they are interpreted the same way wh

Re: [HACKERS] Prettification versus dump safety

2009-11-20 Thread Greg Sabino Mullane
-BEGIN PGP SIGNED MESSAGE- Hash: RIPEMD160 > (1) change pg_dump to not prettify trigger definitions at all, or > (2) change pg_get_triggerdef from the submitted patch so that it > doesn't reduce parenthesization even in "pretty" mode. > > Or somebody could bite the bullet and decouple fo

[HACKERS] Prettification versus dump safety

2009-11-20 Thread Tom Lane
In testing the TRIGGER WHEN patch, I notice that pg_dump is relying on pg_get_triggerdef(triggeroid, true) (ie, "pretty" mode) to dump triggers. This means that trigger WHEN conditions will be dumped without adequate parenthesization to ensure they are interpreted the same way when loaded into fut