Dblink and ISDN - Mailing list pgsql-hackers

From Darko Prenosil
Subject Dblink and ISDN
Date
Msg-id 012201c1da1f$fd4df2f0$f600000a@darko
Whole thread Raw
List pgsql-hackers
We have a request from our customers to link two database servers through the ISDN link.
 
We found the dblink in the contrib directory, and it works ,but there is one big problem.
I'll try to explain it using the sample from README.dblink:
 
SAMPLE:
 create view myremotetable as
 select dblink_tok(t1.dblink_p,0) as f1, dblink_tok(t1.dblink_p,1) as f2
 from (select dblink('hostaddr=127.0.0.1 port=5432 dbname=template1 user=postgres password=postgres'
                    ,'select proname, prosrc from pg_proc') as dblink_p) as t1;
 
select f1, f2 from myremotetable where f1 like 'bytea%';
When the select is executed:
 
    1. all the data from table pg_proc are retrieved from remote database
    2. then where clause is executed against that data (on the local side)
 
This behaviour is OK if the whole story is happenning on local network, but
in our case data should be send through slow ISDN connection.
 
Is it possible to write a rule that uses the current SQL expression and sends this expression to the remote database ?
In this case only wanted data would be send through the network.
 
Thank You in advance !

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: inserting user defined types through a rule?
Next
From: Robert Schrem
Date:
Subject: Re: timeout implementation issues, lock timeouts