Received: from localhost (unknown [200.46.204.183]) by developer.postgresql.org (Postfix) with ESMTP id D5EE32E0076 for ; Thu, 3 Apr 2008 16:27:02 -0300 (ADT) Received: from developer.postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 53888-04 for ; Thu, 3 Apr 2008 16:26:59 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from po-out-1718.google.com (po-out-1718.google.com [72.14.252.156]) by developer.postgresql.org (Postfix) with ESMTP id 5AAA22E0074 for ; Thu, 3 Apr 2008 16:26:57 -0300 (ADT) Received: by po-out-1718.google.com with SMTP id y22so525756pof.3 for ; Thu, 03 Apr 2008 12:26:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; bh=JpDKHY2kqTYS92GTRK2EZsMYfwz1hKzvhTvljY/53h0=; b=VmzXiHO9jMdS+2FWwGuTV2qUnhzDOzamLIzPNGMfEVrCUh4sxiDV0j+0z+dZKQPNoWO0XCetQ5v7iz2l1cwj0wI1HrhmZoptQ5gq11d0v/1cMQksfG/lISmianxUjSxXrV0jUf1pZMtjunrcHsTqzgIIn6n5hrB3cj0EHF1bRDo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=ost+jhgQQhixX8GJYGMp5m5jHEk51Mn8xCdek98cabtVX5W0Din0jYskngLJMLCsknG8Z5ywJWSP+vliGn7C2oveXFlFiEnghurenZ65EeTISkwAduqAs0GT2tR07J2VyzViGRsYNqhNEahHpJqIKHjGIxQmGEDbHkUy5jSjsOU= Received: by 10.141.193.1 with SMTP id v1mr199263rvp.73.1207250812943; Thu, 03 Apr 2008 12:26:52 -0700 (PDT) Received: by 10.140.148.6 with HTTP; Thu, 3 Apr 2008 12:26:52 -0700 (PDT) Message-ID: <95f6bf9b0804031226h1071afa4l2c24e1103679c45d@mail.gmail.com> Date: Thu, 3 Apr 2008 21:26:52 +0200 From: "Marcin Krawczyk" To: "Shane Ambler" Subject: Re: connections between servers Cc: pgsql-sql@postgresql.org In-Reply-To: <47F51563.9060108@Sheeky.Biz> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_3309_18331064.1207250812936" References: <95f6bf9b0804031000r6c582264j83252541a9fb9da9@mail.gmail.com> <47F51563.9060108@Sheeky.Biz> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.001 tagged_above=0 required=5 tests=HTML_MESSAGE=0.001 X-Spam-Level: X-Archive-Number: 200804/26 X-Sequence-Number: 30565 ------=_Part_3309_18331064.1207250812936 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Thanks a lot, I'll give it a try. regards mk 2008/4/3, Shane Ambler : > > Marcin Krawczyk wrote: > > > Hi all. I was wondering if it's possible for a trigger to perform > > operations > > on a database on different server? I saw somewhere that there's a piece > > of > > software that allows conneciotns between different databases, but what > > about > > different servers? I also thought about using perl, would it be possible > > to > > connect to different server from within perl trigger? > > Thanks in advance. > > > > regards > > mk > > > > Yes it is possible. A PL/Perl trigger is one option you have. > > dblink (in contrib) and dbi-link, dblink-tds, oralink and odbclink are > other options at pgfoundry.org depending on your needs. > > > There was a recent discussion in the general mailing list about this. > > http://archives.postgresql.org/pgsql-general/2008-03/msg01343.php > > > > > > -- > > Shane Ambler > pgSQL (at) Sheeky (dot) Biz > > Get Sheeky @ http://Sheeky.Biz > ------=_Part_3309_18331064.1207250812936 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Thanks a lot, I'll give it a try.

regards
mk

2008/4/3, Shane Ambler <pgsql@sheeky.biz>:
Marcin Krawczyk wrote:
Hi all. I was wondering if it's possible for a trigger to perform operations
on a database on different server? I saw somewhere that there's a piece of
software that allows conneciotns between different databases, but what about
different servers? I also thought about using perl, would it be possible to
connect to different server from within perl trigger?
Thanks in advance.

regards
mk

Yes it is possible. A PL/Perl trigger is one option you have.

dblink (in contrib) and dbi-link, dblink-tds, oralink and odbclink are other options at pgfoundry.org depending on your needs.


There was a recent discussion in the general mailing list about this.

http://archives.postgresql.org/pgsql-general/2008-03/msg01343.php





--

Shane Ambler
pgSQL (at) Sheeky (dot) Biz

Get Sheeky @ http://Sheeky.Biz

------=_Part_3309_18331064.1207250812936--