Re: Where is the logig to create a table file?

From: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
To: pashkin(dot)elfe(at)gmail(dot)com
Cc: jacktby(at)gmail(dot)com, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Where is the logig to create a table file?
Date: 2023-02-07 04:56:59
Message-ID: 20230207.135659.25944268928443873.horikyota.ntt@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

At Fri, 3 Feb 2023 13:44:46 +0400, Pavel Borisov <pashkin(dot)elfe(at)gmail(dot)com> wrote in
> Hi, Jack
>
> On Fri, 3 Feb 2023 at 13:19, jacktby(at)gmail(dot)com <jacktby(at)gmail(dot)com> wrote:
> >
> > When I use 'create table t(a int);'; suppose that this table t's oid is 1200,
> > then postgres will create a file named 1200 in the $PGDATA/base, So where
> > is the logic code in the internal?
> >
> heapam_relation_set_new_filenode()->RelationCreateStorage()

Or if you are searching for the logic to determin the file name, see
GetNewRelFileNumber().

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2023-02-07 05:01:48 Re: Time delayed LR (WAS Re: logical replication restrictions)
Previous Message Andres Freund 2023-02-07 04:49:57 Re: Exit walsender before confirming remote flush in logical replication