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 1t6x7v-00GdF3-SP for pgsql-general@arkaria.postgresql.org; Fri, 01 Nov 2024 19:16:07 +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 1t6x7u-00GmaG-5c for pgsql-general@arkaria.postgresql.org; Fri, 01 Nov 2024 19:16:06 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t6x7t-00Gma8-Pq for pgsql-general@lists.postgresql.org; Fri, 01 Nov 2024 19:16:06 +0000 Received: from sm-r-016-dus.org-dns.com ([89.107.70.6]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t6x7r-0040XF-5Z for pgsql-general@lists.postgresql.org; Fri, 01 Nov 2024 19:16:04 +0000 Received: from smarthost-dus.org-dns.com (localhost [127.0.0.1]) by smarthost-dus.org-dns.com (Postfix) with ESMTP id 9E67CA21DC for ; Fri, 1 Nov 2024 20:16:01 +0100 (CET) Received: by smarthost-dus.org-dns.com (Postfix, from userid 1001) id 92061A21F2; Fri, 1 Nov 2024 20:16:01 +0100 (CET) X-Spam-Status: No, score=-1.1 required=5.0 tests=AWL,BAYES_00,HTML_MESSAGE, KAM_INFOUSMEBIZ,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED, RCVD_IN_VALIDITY_RPBL_BLOCKED,SPF_HELO_PASS,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 Received: from ha01s018.org-dns.com (ha01s018.org-dns.com [62.108.32.138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smarthost-dus.org-dns.com (Postfix) with ESMTPS id 39BA9A21DC for ; Fri, 1 Nov 2024 20:16:01 +0100 (CET) Authentication-Results: ha01s018.org-dns.com; spf=pass (sender IP is 127.0.0.1) smtp.mailfrom=thiemo@gelassene-pferde.biz smtp.helo=ha01s018.org-dns.com Received-SPF: pass (ha01s018.org-dns.com: connection is authenticated) Received: from [5.83.191.177] ([5.83.191.177]) by webmail.gelassene-pferde.biz (Horde Framework) with HTTPS; Fri, 01 Nov 2024 20:16:00 +0100 Date: Fri, 01 Nov 2024 20:16:00 +0100 Message-ID: <20241101201600.Horde.Br4fPP8BFAAwzFoMaM8_eJS@webmail.gelassene-pferde.biz> From: thiemo@gelassene-pferde.biz To: PostgreSQL General Subject: Re: Plans for partitioning of inheriting tables References: <5757acdc-39ed-4642-a449-26e47b1bcf95@gelassene-pferde.biz> <20241101094106.Horde.TwPSs9YUgJ5v-_M-4ltwoeh@webmail.gelassene-pferde.biz> <14c1eb8c-a853-43b3-a1ea-b105bfd6c99b@aklaver.com> <20241101182110.Horde.P_w6KptTjJNeM1X9Asg5bE3@webmail.gelassene-pferde.biz> <6bc57377-52e1-496a-b9d6-4cd9dc84d92e@aklaver.com> In-Reply-To: Accept-Language: de Content-Type: multipart/alternative; boundary="=_sn2kdYq_OXLYGM_VCFywDGZ" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-PPP-Message-ID: <173048856113.3777180.3832313608784242625@ha01s018.org-dns.com> X-PPP-Vhost: gelassene-pferde.biz X-POWERED-BY: wint.global - AV:CLEAN SPAM:OK List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk This message is in MIME format. --=_sn2kdYq_OXLYGM_VCFywDGZ Content-Type: text/plain; charset=utf-8; format=flowed; DelSp=Yes Content-Description: =?utf-8?b?U8OzbG8=?= texto Content-Disposition: inline Content-Transfer-Encoding: 8bit Thanks, I shall have a look into it. I was under the assumption the the create table like would create no more than a structural copy. Torsten F��rtsch escribi��: > Thiemo, �� > it looks to me like you are using inheritance just to make sure > your SOURCES and TOPO_FILES tables have some common columns. If you > are not actually querying the TEMPLATE_TECH table and expect to see > all the rows from the other 2 tables in that one table combined, > then you could use CREATE TABLE (LIKE ...) instead of inheritance. > That way your "child" tables would become normal tables and you > could use declarative partitioning on them. > �� > Even if you are querying the TEMPLATE_TECH table, you could still > do that by turning the TEMPLATE_TECH table into a view which > performs a UNION ALL over the other tables. --=_sn2kdYq_OXLYGM_VCFywDGZ Content-Type: text/html; charset=utf-8 Content-Description: Mensaje HTML Content-Disposition: inline

Thanks, I shall have a look into it. I was under the assumption the the create table like would create no more than a structural copy.

Torsten Förtsch <tfoertsch123@gmail.com> escribió:

Thiemo,
 
it looks to me like you are using inheritance just to make sure your SOURCES and TOPO_FILES tables have some common columns. If you are not actually querying the TEMPLATE_TECH table and expect to see all the rows from the other 2 tables in that one table combined, then you could use CREATE TABLE (LIKE ...) instead of inheritance. That way your "child" tables would become normal tables and you could use declarative partitioning on them.
 
Even if you are querying the TEMPLATE_TECH table, you could still do that by turning the TEMPLATE_TECH table into a view which performs a UNION ALL over the other tables.


--=_sn2kdYq_OXLYGM_VCFywDGZ--