Re: postgresql FDW vs dblink for DDL - Mailing list pgsql-general

From Achilleas Mantzios - cloud
Subject Re: postgresql FDW vs dblink for DDL
Date
Msg-id 1a884667-8474-dd01-d55f-1135724912f5@cloud.gatewaynet.com
Whole thread Raw
In response to Re: postgresql FDW vs dblink for DDL  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: postgresql FDW vs dblink for DDL
List pgsql-general
On 9/8/24 23:46, Adrian Klaver wrote:
> On 9/8/24 13:04, Achilleas Mantzios wrote:
>> Hi
>>
>> for remote DDL execution (such as CREATE TABLE) is dblink my only 
>> option?
>
> You will need to define in what context you are considering options.
>
> For instance you can do remote DDL operations by passing a command or 
> script via psql.

Thank you Adrian,

I was thinking of wrapping the DDL around a FUNCTION that will handle 
both the local and the (possibly various logical subscriptions), so that 
my programmers don't need to write extra scripts.

And the thing is that this creation via DDL is inside our design. 
Certain users create some backup tables of the public data in their own 
schema (via our app), then do some manipulations on the public data, 
then restore to the public or merge with the backups. When done, those 
backup tables are dropped. So the DDL is inside the app. And the 
question was if dblink is my only option, in the sense of doing this in 
a somewhat elegant manner. (and not resort to scripts, etc)

>
>>
>> thanks
>>
>>
>>
>>
>



pgsql-general by date:

Previous
From: Dominique Devienne
Date:
Subject: Re: Faster data load
Next
From: KK CHN
Date:
Subject: ssh to DB server and su normal users very slow :