Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jgZ7d-0006Sq-57 for pgsql-general@arkaria.postgresql.org; Wed, 03 Jun 2020 19:32:21 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jgZ7c-0005KV-1L for pgsql-general@arkaria.postgresql.org; Wed, 03 Jun 2020 19:32:20 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jgZ7b-0005KO-ND for pgsql-general@lists.postgresql.org; Wed, 03 Jun 2020 19:32:19 +0000 Received: from mail-pl1-x641.google.com ([2607:f8b0:4864:20::641]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jgZ7Y-0007F0-2o for pgsql-general@lists.postgresql.org; Wed, 03 Jun 2020 19:32:18 +0000 Received: by mail-pl1-x641.google.com with SMTP id t16so1158504plo.7 for ; Wed, 03 Jun 2020 12:32:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:message-id:date:to; bh=fxemMkeiS95yg0HZGjvCskFigRd32kUFO32pco6mPWY=; b=pKRRd2iDuUkDpNb+GIIcTRIObaQbCBECv1Wz5SvLY+BO2pflfPj1olVEJFyvvNmwiu syJkigNeD6QlmrkNqaglJJvnBunK07lP1BNM6Tilqy6JCbejoZAndbYxBrQKJcVwfRId PEiIsfgJZBJE/vs60wFircalL0ztt97f80Y6SAlmPibp1IQZ67uz8T3O18G+EmjEAtGF RKOW8NnZnxo32XdKY9qAeI6KowxZxuix9WJ3jJ7BZzOTPkxscWGkctb6jkf0mU8HxOf3 mSoKmk+IroTPWRf/seuNOb/qNyHDpixK/WwyDCVmpjTjRdTjeUb1cIj1fJfBxcyMOjF8 xceA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:message-id:date:to; bh=fxemMkeiS95yg0HZGjvCskFigRd32kUFO32pco6mPWY=; b=mBEN6qm7vj8UuuGouKiVw6YNGJxf5ENQqPJjo99JRJ0AP1hCX8nGG+o6URei9ucBtF /eROHk8hVGM1fxBE6eHGTepq2a/7jWsze/oxSu+/MpWaQwdCuOxoGzI18E9cGs4H94vV oZdHQ/nIf25nke1FbF6vNyFlE4xOYurcoenGqkaIakpYkVsuIV3anvs7Ar95t9t2uWy4 KWgYttrM+cLmFyc1RXE41mEauuIIVGRfFNR1MOtkCL8UsF/IzVTerOfrewNK8a986Cm2 J4PTjJEqXyfsAod4G/bsNQdGKt2n4N20LR+VAIOzxgo2ID+0NyQ5lqQOXVKt1w5CU3hb 1YGQ== X-Gm-Message-State: AOAM530aMPur3QOK+xVJx1W/9b+xWtCBKaNrevZ6ec96SfyfC/lQOdjQ hvd3jJiqJJA4EEFko8ZZ1e9rz/4b2dI= X-Google-Smtp-Source: ABdhPJwn96zcSsV4mM50FuvUMFigElO8yAJa1LMGe9n1E2OqbPm2slVOx3CbdsSlxMZAuzYPxTnXkQ== X-Received: by 2002:a17:90b:1244:: with SMTP id gx4mr1655686pjb.136.1591212734384; Wed, 03 Jun 2020 12:32:14 -0700 (PDT) Received: from ?IPv6:2600:8801:8800:4::18? ([2600:8801:8800:4::18]) by smtp.gmail.com with ESMTPSA id e26sm2229817pgl.27.2020.06.03.12.32.13 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 03 Jun 2020 12:32:13 -0700 (PDT) From: Guyren Howe X-Mailbutler-Message-Id: BBF9B6A9-88B7-477A-AE2D-BEA53C41F31F Content-Type: multipart/alternative; boundary="Apple-Mail=_17A222E4-43DE-48C7-AFE4-18D8F03086D3" Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\)) Subject: Can we get SQL Server-like cross database queries Message-Id: <84A3D231-6AFB-4981-AA09-18FBC7772B77@gmail.com> Date: Wed, 3 Jun 2020 12:31:57 -0700 To: "pgsql-general@lists.postgresql.org" X-Mailer: Apple Mail (2.3608.80.23.2.2) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --Apple-Mail=_17A222E4-43DE-48C7-AFE4-18D8F03086D3 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 One of the few really useful features of SQL Server that Postgres = doesn=E2=80=99t have is straightforward cross-database queries. You can reference any table in any database on the same server you=E2=80=99= re on as database.schema.table. With Postgres, it is necessary to set up a FDW connection between every = database where you want to perform a query and the database you want to = query. In an analytics environment where a single server might have a = hundred or so smaller databases, this is a grossly inefficient = proposition. Is it practical to provide the SQL Server-like feature in Postgres? --Apple-Mail=_17A222E4-43DE-48C7-AFE4-18D8F03086D3 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 One = of the few really useful features of SQL Server that Postgres doesn=E2=80=99= t have is straightforward cross-database queries.

You can reference any table in any = database on the same server you=E2=80=99re on as = database.schema.table.

With Postgres, it is necessary to set up a FDW connection = between every database where you want to perform a query and the = database you want to query. In an analytics environment where a single = server might have a hundred or so smaller databases, this is a grossly = inefficient proposition.

Is it practical to provide the SQL Server-like feature in = Postgres?
3D""= --Apple-Mail=_17A222E4-43DE-48C7-AFE4-18D8F03086D3--