Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qrUC4-004Uqk-3z for pgsql-admin@arkaria.postgresql.org; Sat, 14 Oct 2023 02:15:56 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qrUC1-005OTE-Ns for pgsql-admin@arkaria.postgresql.org; Sat, 14 Oct 2023 02:15:54 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qrUC1-005OT6-AG for pgsql-admin@lists.postgresql.org; Sat, 14 Oct 2023 02:15:54 +0000 Received: from mail-yw1-x1130.google.com ([2607:f8b0:4864:20::1130]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1qrUBt-000T6p-AL for pgsql-admin@lists.postgresql.org; Sat, 14 Oct 2023 02:15:53 +0000 Received: by mail-yw1-x1130.google.com with SMTP id 00721157ae682-59e88a28b98so23235957b3.1 for ; Fri, 13 Oct 2023 19:15:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1697249744; x=1697854544; darn=lists.postgresql.org; h=in-reply-to:from:references:to:content-language:subject:user-agent :mime-version:date:message-id:from:to:cc:subject:date:message-id :reply-to; bh=ajjuNG6Dz8L+gdjjn5rfrRZyvUm+EbqVzk9zRGlxjOE=; b=PNik8oB9VYLHsnvy+40XbhQJfadv8kBE0RxU6ahxx7UhstFKBlgsZtCYDpqoYdbPEW rNOQwB4w6f0IxFfp4oOdJ7GkzlBxnPbFSctd6XQZyjYbFnaKamRNC7LE9u8sGOG0gFZB P9io+o7kMF/kkGSX5pVWODJe2AIIY0IxzlsalzNdU2OAgT2IdlfMjYkRW+q3YnsdJt1L BcqYr5dC523QUwfiKUgJAX0hLkIjT8+JqLtCOKmPD9rH93MyfuZFsQMKOlm0Qg4dFmO+ alsl6AT4d4cVQNFGl7OlwlkXCxidWsXCDj1f8+L9xAciu3T4mxNQ+z6Sktcl3A9mYFAK 5O/A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697249744; x=1697854544; h=in-reply-to:from:references:to:content-language:subject:user-agent :mime-version:date:message-id:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=ajjuNG6Dz8L+gdjjn5rfrRZyvUm+EbqVzk9zRGlxjOE=; b=vQRehchHyM6SpcTmj+ySj3Z2bbbhJLJEYF2ZXcYzU1jW+o+q5AtbiNOo/+lUqpXBAC PC5jwT+5ZhXt9CqtfKanL87w7OhHq4qctDJZfAsyzQVGdlzE4vha6yYjl+Nk8OixO5Bk qbOXbUs//Ty3E86b1GSiYdZYCICP01UO1cndHcRVj7KM80dtjU1Gk3KU2Pfshn8sj5MI +8G4PUKCV7mVWevwrIYe422/lIH8tiNBhJZFRcwovgRvzvSVU+cVot6x8UBo7P8NdtKf 6MyTABqG7LOSzvVGc3lH015G8hXE6fsG+iYpH4DUEi/V/xvzofWw+blGmM6fQUC9E/Am tiuQ== X-Gm-Message-State: AOJu0Yw/qnC9lwbT3D+RAaT4exHs21C2Z/SK11EBRDJGyuybLVZ/ZU+M 9aEeKijICKCdjzK0D09kl6e/NMKw1m8= X-Google-Smtp-Source: AGHT+IFzGYuURXVYkCH4+hV3aZTgnHpKjulyXWH3evh1cKwrHA4g4CSgW2nqspBd6bFgEBM7NI4bSA== X-Received: by 2002:a81:4e8c:0:b0:5a7:d4d7:aaa1 with SMTP id c134-20020a814e8c000000b005a7d4d7aaa1mr1170864ywb.16.1697249743900; Fri, 13 Oct 2023 19:15:43 -0700 (PDT) Received: from ?IPV6:2600:1700:bd2c:b810:384f:f089:304b:94b5? ([2600:1700:bd2c:b810:384f:f089:304b:94b5]) by smtp.googlemail.com with ESMTPSA id m65-20020a0de344000000b005a4c2316412sm222039ywe.137.2023.10.13.19.15.43 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 13 Oct 2023 19:15:43 -0700 (PDT) Content-Type: multipart/alternative; boundary="------------XnBpJkqfuiwU1ZAzAbLIbNOe" Message-ID: Date: Fri, 13 Oct 2023 21:15:43 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: Connecting 2 databases within the same instance Content-Language: en-US To: pgsql-admin@lists.postgresql.org References: <1546706033.6267226.1697247420904@mail.yahoo.com> From: Ron In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk This is a multi-part message in MIME format. --------------XnBpJkqfuiwU1ZAzAbLIbNOe Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Google is your friend.  Searching for "postgresql dblink" and "postgresql fdw" take you right to the documentation: https://www.postgresql.org/docs/15/dblink.html https://www.postgresql.org/docs/current/postgres-fdw.html DB Link is much older, while FDW has better syntax and is usually faster: " The functionality provided by this module overlaps substantially with the functionality of the olderdblink module. But|postgres_fdw|provides more transparent and standards-compliant syntax for accessing remote tables, and can give better performance in many cases. " On 10/13/23 20:40, M Sarwar wrote: > Hi, > Are you saying that Db Link is existing in the Postgress or just referring > to FDW ? > Sarwar > > > > > Sent from my Galaxy > > > > -------- Original message -------- > From: swastik Gurung > Date: 10/13/23 9:37 PM (GMT-05:00) > To: pgsql-admin@postgresql.org, M Sarwar > Subject: Re: Connecting 2 databases within the same instance > > I think any of the two contrib module dblink and/or postgres_fdw could help > On Saturday, 14 October 2023 at 03:38:33 GMT+5:45, M Sarwar > wrote: > > > > Hello, > >  I have one instance and two database within it. What is the simplest > approach which I can adopt to connect these 2 database to one another. > > I want to have the ability to connect to any table. For example database > link in Oracle databases. How can I deploy this gracefully? > > Thanks, > > Sarwar > -- Born in Arizona, moved to Babylonia. --------------XnBpJkqfuiwU1ZAzAbLIbNOe Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit Google is your friend.  Searching for "postgresql dblink" and "postgresql fdw" take you right to the documentation:
https://www.postgresql.org/docs/15/dblink.html
https://www.postgresql.org/docs/current/postgres-fdw.html

DB Link is much older, while FDW has better syntax and is usually faster:
"
The functionality provided by this module overlaps substantially with the functionality of the older dblink module. But postgres_fdw provides more transparent and standards-compliant syntax for accessing remote tables, and can give better performance in many cases.
"

On 10/13/23 20:40, M Sarwar wrote:
Hi,
Are you saying that Db Link is existing in the Postgress or just referring to FDW ?
Sarwar




Sent from my Galaxy



-------- Original message --------
From: swastik Gurung <gurung_swastik@yahoo.com>
Date: 10/13/23 9:37 PM (GMT-05:00)
Subject: Re: Connecting 2 databases within the same instance

I think any of the two contrib module dblink and/or postgres_fdw could help
On Saturday, 14 October 2023 at 03:38:33 GMT+5:45, M Sarwar <sarwarmd02@outlook.com> wrote:



 

 

Hello,

 

 I have one instance and two database within it. What is the simplest approach which I can adopt to connect these 2 database to one another.

I want to have the ability to connect to any table. For example database link in Oracle databases. How can I deploy this gracefully?

 

Thanks,

Sarwar


--
Born in Arizona, moved to Babylonia.
--------------XnBpJkqfuiwU1ZAzAbLIbNOe--