Re: [GENERAL] How can I merge two tables?

2011-09-02 Thread Jeff Davis
On Thu, 2011-09-01 at 13:09 -0400, Jerry LeVan wrote: As time goes by the tables on the various computers get out of sync. Is there an elegant way I can get all of the differences (uniquely) merged into a single table? You can try a query involving NOT EXISTS, combined with dblink:

[GENERAL] How can I merge two tables?

2011-09-01 Thread Jerry LeVan
Hi, I have tables on my various computers that looks like: Table public.registrations Column | Type | Modifiers | Storage | Description --+--+---+--+- software | text | | extended | id | text | | extended |

Re: [GENERAL] How can I merge two tables?

2011-09-01 Thread Diego Augusto Molina
Mmm... maybe if you can dump them as inserts you'll be able to restore them in one DB only. Important: make the restore connection autocommit (i.e. don't put the --single-transaction flag). That way individual INSERTs will fail without affecting the other data if that INSERT violates the PK. This

Re: [GENERAL] How can I merge two tables?

2011-09-01 Thread Ondrej Ivanič
Hi, On 2 September 2011 03:09, Jerry LeVan jerry.le...@gmail.com wrote: I keep registration numbers for software and login/passwords for various organizations, etc… As time goes by the tables on the various computers get out of sync. Is there an elegant way I can get all of the differences

[GENERAL] How can I merge two tables?

2011-09-01 Thread Jerry LeVan
Hi, I have tables on my various computers that looks like: Table public.registrations Column | Type | Modifiers | Storage | Description --+--+---+--+- software | text | | extended | id | text | | extended |