On Wed, 14 Mar 2018 11:28:59 -0700
Paul Jungwirth <pj@illuminatedcomputing.com> wrote:
> > EXCLUDE USING gist (id WITH =, as_of_date WITH &&)
> null), but maybe there are other primary-key duties it doesn't meet,
> like defining foreign keys that reference it. I've been on-and-off
The PK does provide a unique index.
It may be worth adding and index on
id where ( upper as_of_date = infinity )
for faster searches of current id's (assuming, of course, that there
is an infinite value for upper of as_of_date).
You will also need a PK if the table is used in foreign key
constraints -- the other table has to ref this table's PK.
--
Steven Lembark 1505 National Ave
Workhorse Computing Rockford, IL 61103
lembark@wrkhors.com +1 888 359 3508