Re: WIP: System Versioned Temporal Table - Mailing list pgsql-hackers

From Daniel Westermann
Subject Re: WIP: System Versioned Temporal Table
Date
Msg-id 162981111425.22084.8061245050741782223.pgcf@coridan.postgresql.org
Whole thread Raw
In response to Re: WIP: System Versioned Temporal Table  (Simon Riggs <simon.riggs@enterprisedb.com>)
List pgsql-hackers
Hi,

quick note: The documentation for this patch mentions:

 The <literal>starttime</literal> column
+    will be automatically added to the Primary Key of the table.

A quick tests shows that the endtime column is added instead:

postgres=# create table t1 ( a int primary key generated always as identity, b text ) with system versioning;
CREATE TABLE
postgres=# \d t1
                                      Table "public.t1"
  Column   |           Type           | Collation | Nullable |            Default            
-----------+--------------------------+-----------+----------+-------------------------------
 a         | integer                  |           | not null | generated always as identity
 b         | text                     |           |          | 
 starttime | timestamp with time zone |           | not null | generated always as row start
 endtime   | timestamp with time zone |           | not null | generated always as row end
Indexes:
    "t1_pkey" PRIMARY KEY, btree (a, endtime)

Regards
Daniel

pgsql-hackers by date:

Previous
From: Justin Pryzby
Date:
Subject: Re: PoC/WIP: Extended statistics on expressions
Next
From: Denis Laxalde
Date:
Subject: Re: [PATCH] Disable bgworkers during servers start in pg_upgrade