How to use a trigger to write rows to a remote server - Mailing list pgsql-performance

From Michael Dengler
Subject How to use a trigger to write rows to a remote server
Date
Msg-id e8733d090707180636q45bb5d16vff3e79c2d60d2e83@mail.gmail.com
Whole thread Raw
Responses Re: How to use a trigger to write rows to a remote server
Re: How to use a trigger to write rows to a remote server
Re: How to use a trigger to write rows to a remote server
List pgsql-performance
Hi All,

I am trying to find out how to use a trigger function on a table to copy any inserted row to a remote PG server.

ie:

Row X is inserted into TableX in DB1 on server1....TableX trigger function fires and contacts DB2 on server2 and inserts the row into TableY on server2.

I've looked around and can't see to find this. Essentially I need to know how to write to a remote DB server from within a trigger function.

This is not replication, I'm not interested in a full blown trigger based replication solution.

Any Help is greatly appreciated!

Thanks

Mike

pgsql-performance by date:

Previous
From: Michael Stone
Date:
Subject: Re: insert vs select into performance
Next
From: Heikki Linnakangas
Date:
Subject: Re: How to use a trigger to write rows to a remote server