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.96) (envelope-from ) id 1wO1Sq-001Fzd-1C for pgsql-general@arkaria.postgresql.org; Fri, 15 May 2026 22:57:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wO1So-001ryM-1L for pgsql-general@arkaria.postgresql.org; Fri, 15 May 2026 22:57:02 +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.96) (envelope-from ) id 1wO1So-001ryE-00 for pgsql-general@lists.postgresql.org; Fri, 15 May 2026 22:57:02 +0000 Received: from mail-ot1-x32c.google.com ([2607:f8b0:4864:20::32c]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wO1Sl-00000000pJz-2BGU for pgsql-general@postgresql.org; Fri, 15 May 2026 22:57:01 +0000 Received: by mail-ot1-x32c.google.com with SMTP id 46e09a7af769-7dcd9061b1aso372692a34.2 for ; Fri, 15 May 2026 15:56:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1778885818; cv=none; d=google.com; s=arc-20240605; b=Ismz+bE64MX1dwIhuge8+P6hwabKyMgjIsbqDdRFPqxBqiTgVr69vEx2pyD6Ewx0nM vVDOumGZSztYEvLBwFZWAvUHbhRYCcLOZQVK7XYXpy4VklTWVjS76WgLY1qHbgLcyYFQ mnzEQc3uGSlVs+bx2ziTWwBcpMC7KFHvslowB1JFyJo2F6xifOWE+Hjqx35VEQAf+9mC NqJYrujvsQCcPE4uuedFVM3QhLx+RG/OIUTWjp2w5L8AbCEPf+gOhbIc9+bk+LkW5Sbb ryBui9RXRzpCu4x7pGbu+xLFQvVySbXqKDsYK79waK8aIuvdj6mvN6Hqy0l2QkXd87Jl Qsug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=nPZzLtB4qQLlcfrmDjwAu2kKgjTBWDCSdeVGbnOOzEI=; fh=xlEumQ/ItFTuseMU8abXWvw+r9sDum0uiRjXXzYxDTI=; b=UOTEwo7HIOwCAbB3jGRoZIZOL8DxVGZph4VcqbHDFCZRDZPA3cYyQngSXNg1SrM18M fCaKdESB65oYZvk/pRDY9d4WR6XnqJY64GxdoB3uvZ0lTnOFKKLFuWY1M9CrjMRdQ/HT 0DHs5gJhrJiLJTX+qmQdJm1mqMrc22ibDj7ZhcgvkSeF2gpHMlFfrCNHbC7vqp8qzX1K lGSojdmwDX9T3e+dt6BNq9dGVC4cANc9Wvv82MlBzgi7GFVLCOrVvccdeV1SdWBZjoOm 3MqL+HF+EMdC/xQl4XruOoPFAAt+c9P1IXLiql86cJR4QNJUWolf8udngRAmx+F5tKsZ I3ig==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1778885818; x=1779490618; darn=postgresql.org; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=nPZzLtB4qQLlcfrmDjwAu2kKgjTBWDCSdeVGbnOOzEI=; b=J9SVvjOk0jdLoHzL7YB3fP1nXBqpCaCWzD9OIXHuAViABVpT7eOHc8Ui+6s4KGW5Dp p8fEwWoJK7dGD2GUFrqD9HZZL5rpbS8gi82V7LiAaoRQ0zgXRkLjgQEbEcUtzpahpmAZ gVUrbeNkFFxwL/NKWfSxgdWGKxJlQh4lsvSmQQlTtf7iMZiFfhF82hUckyHD098/TDq1 c75Z39nQZgaCGphBvvwSByv4RP+22xRcU3p2NPhfzFzPc1W8gbpGCmkRJjDdWhn5eTDg AQ3hOLrMCX4KpJzK5ssyYMkrp/j5u1TkddIWIZVVeJo7xJD3a7O36hyIJp06Xjp9nymT zR5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778885818; x=1779490618; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=nPZzLtB4qQLlcfrmDjwAu2kKgjTBWDCSdeVGbnOOzEI=; b=Fw9GwV3NxQ2XUYt9d8cryh/h5HnVtvgBTAkSuDSqyoBJ8APgl5sjnfGEWK4XX9GQe2 i+Zmc2LZbWXrtP7567R2ShS9lKcpt1upjBM4xrmEi32L5aczGa1lMb2ffc804mHtxuEP ftN4WtBGpGmGRGzgtROryzjk+gIudKfYOMkJ5K4kKW2iS7dO7oE10r0DzdJITwUzkFi/ OhFQN6QxT1VksL4N4B2n5YiPUj4kFfpD7Mqx0CIEDCbR48s+JfADiiCwKJetgi2xCJp2 kNtjVszJYqrakd99SoOHJo4B/yHCwLitjO9deeUCKg805EFi2B+VKCE4iZQ+gELdpvSB lUGQ== X-Gm-Message-State: AOJu0YxWo9nzuoRv+boRaETy7/SIT2f2PmnAtxbl5855qZtrBSu0I5y5 aEq7KT1ezliHnQWchiTCQmLGeJ/ujqJBftDQYaVH+etF5C9UfzYGQgTMieUdQ9U8drfocDFpfaP N1uYICzf3rYd9v1DMJgk45i34P9ZC4m2cXw== X-Gm-Gg: Acq92OEd7QGWxBN73M2+ML5p1g1PheWI862cSlXZrVtc8/8QsGx66vOmscMs6l0mW7/ Ajc7IK9flVTV2Zj0gig3ZIiHWtdYEm7BUT6UuV7FrvvORdDfwrSOI7cRaligTUiRpSbbcaLqk5C F4s+DSQV3vs8SP9VoeJg8756MK0yEsnZU6VnIDv6B2cqm8cO1WZ5PZYQEM6Y8C7GbGFDYbosV7J XG3XX+G5CLlg4n1qagEcI1hC0tiIDpXpYKeqog/LnSsS+tnxHhLhXg8XS1pP7rry8AztXFPCgrn IyKQsZyJ/BNRPjg0+ww= X-Received: by 2002:a05:6830:82ce:b0:7dc:cadd:f95d with SMTP id 46e09a7af769-7e4ea06ff26mr4197752a34.2.1778885817962; Fri, 15 May 2026 15:56:57 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Ron Johnson Date: Fri, 15 May 2026 18:56:46 -0400 X-Gm-Features: AVHnY4Ih4iBGTBb_Ka8RtPve2OOEzIvRd5YHXZhofu1WDYvb0HpLAxs6sp_115k Message-ID: Subject: Re: Suggestion for Easier Cross-Database Query Handling in PostgreSQL To: "pgsql-general@postgresql.org" Content-Type: multipart/alternative; boundary="0000000000004694cc0651e3216d" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000004694cc0651e3216d Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Frank, Why doesn't the shared OID space make cross-database queries possible? SQL Server does it, so the idea isn't that far-fetched. On Fri, May 15, 2026 at 6:18=E2=80=AFPM Frank Heikens w= rote: > > Hi Shivam, > > Thank you for your feedback. > > One important difference is terminology. > > In MySQL, CREATE DATABASE and CREATE SCHEMA are essentially the same > command, so what MySQL calls a =E2=80=9Cdatabase=E2=80=9D is effectively = a schema > (namespace). > > PostgreSQL also supports querying across schemas natively, so the same > functionality is already available when the objects are in the same > PostgreSQL database. > > In PostgreSQL, a database is a true isolation boundary with its own > catalogs and connection context. Because of this design, direct joins > across databases are not supported. When this is required, postgres_fdw i= s > the recommended solution. > > So for most MySQL users, the equivalent approach in PostgreSQL is to use > multiple schemas within a single database rather than multiple databases. > > Best regards, > Frank Heikens > > > > > On May 15, 2026, at 3:06=E2=80=AFPM, Shivam Pandey > wrote: > > > > =EF=BB=BF > > Hello PostgreSQL Team, > > > > I would like to share feedback from a developer perspective regarding > cross-database querying in PostgreSQL. > > > > One feature that many developers appreciate in MySQL is the ability to > directly query and join tables across multiple databases within the same > server instance. This approach becomes very useful in real-world situatio= ns > where applications need to access shared or distributed data quickly and > efficiently. > > > > In PostgreSQL, achieving similar functionality often requires additiona= l > setup using extensions such as postgres_fdw or dblink. While these > solutions are powerful and architecturally clean, they can feel complex f= or > developers who are building applications rapidly or migrating from system= s > like MySQL. > > > > It would be valuable if PostgreSQL could provide a more > developer-friendly and simplified native approach for cross-database > querying while still maintaining PostgreSQL=E2=80=99s strong isolation an= d security > principles. > > > > Possible improvements could include: > > > > 1)Simpler syntax for cross-database joins > > 2) Easier configuration for trusted local databases > > 3) Built-in lightweight federation support > > 4) Better onboarding documentation for multi-database use cases > > > > PostgreSQL is already one of the most powerful and respected databases > in the industry. Enhancing developer convenience in this area could make > adoption even smoother for many teams. > > > > Thank you for your incredible work and continuous innovation. > > > > Best Regards, > > Shivam Pandey > --=20 Death to , and butter sauce. Don't boil me, I'm still alive. lobster! --0000000000004694cc0651e3216d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Frank,

Why doesn't the s= hared OID space make cross-database queries possible?=C2=A0 SQL Server does= it, so the idea isn't that far-fetched.

On Fri, M= ay 15, 2026 at 6:18=E2=80=AFPM Frank Heikens <frank@elevarq.com> wrote:

Hi Shivam,

Thank you for your feedback.

One important difference is terminology.

In MySQL, CREATE DATABASE and CREATE SCHEMA are essentially the same comman= d, so what MySQL calls a =E2=80=9Cdatabase=E2=80=9D is effectively a schema= (namespace).

PostgreSQL also supports querying across schemas natively, so the same func= tionality is already available when the objects are in the same PostgreSQL = database.

In PostgreSQL, a database is a true isolation boundary with its own catalog= s and connection context. Because of this design, direct joins across datab= ases are not supported. When this is required, postgres_fdw is the recommen= ded solution.

So for most MySQL users, the equivalent approach in PostgreSQL is to use mu= ltiple schemas within a single database rather than multiple databases.

Best regards,
Frank Heikens



> On May 15, 2026, at 3:06=E2=80=AFPM, Shivam Pandey <shivampandey91199@gmail.c= om> wrote:
>
> =EF=BB=BF
> Hello PostgreSQL Team,
>
> I would like to share feedback from a developer perspective regarding = cross-database querying in PostgreSQL.
>
> One feature that many developers appreciate in MySQL is the ability to= directly query and join tables across multiple databases within the same s= erver instance. This approach becomes very useful in real-world situations = where applications need to access shared or distributed data quickly and ef= ficiently.
>
> In PostgreSQL, achieving similar functionality often requires addition= al setup using extensions such as postgres_fdw or dblink. While these solut= ions are powerful and architecturally clean, they can feel complex for deve= lopers who are building applications rapidly or migrating from systems like= MySQL.
>
> It would be valuable if PostgreSQL could provide a more developer-frie= ndly and simplified native approach for cross-database querying while still= maintaining PostgreSQL=E2=80=99s strong isolation and security principles.=
>
> Possible improvements could include:
>
> 1)Simpler syntax for cross-database joins
> 2) Easier configuration for trusted local databases
> 3) Built-in lightweight federation support
> 4) Better onboarding documentation for multi-database use cases
>
> PostgreSQL is already one of the most powerful and respected databases= in the industry. Enhancing developer convenience in this area could make a= doption even smoother for many teams.
>
> Thank you for your incredible work and continuous innovation.
>
> Best Regards,
> Shivam Pandey


--
Death to <Redacted>, and butter sauce.Don't boil me, I'm still alive.
<Redacted> lobs= ter!
--0000000000004694cc0651e3216d--