About partitioning - Mailing list pgsql-general

From Vincenzo Romano
Subject About partitioning
Date
Msg-id 3eff28921001200220p484ad04dxe941a25f14889b6a@mail.gmail.com
Whole thread Raw
Responses Re: About partitioning  (Adrian von Bidder <avbidder@fortytwo.ch>)
List pgsql-general
A main issue in my case with the suggested (chapter 5.9)
implementation is that child tables need to be created in advance,
For a number of reasons (complex partitioning schemas, rows also
related to the past and the future) it'd be unpractical
to create all of them in advance.
So I'm thinking about an "on demand" creation. I see two options only:
1. I check the child table existence before inserting the row or
2. I create the missing table as the result of an insert error (no table found).

In case 1 I need to inspect the catalog with at least a select, while
in case 2 I need to trap errors.
In my (little) experience trapping errors is slow, so I would go for option 1.

Unless there is a better advise.

--
Vincenzo Romano
NotOrAnd Information Technologies
NON QVIETIS MARIBVS NAVTA PERITVS

1

pgsql-general by date:

Previous
From: "A. Kretschmer"
Date:
Subject: Re: Size of row-metadata?
Next
From: tmp
Date:
Subject: Re: Size of row-metadata?