> speak in the \copy command.  I.e. you wouldn't use inserts to load your 
> data, you'd use a bulk copy, which bypassess all the serial / IDENTITY 
> stuff.  Basically, with the IDENTITY type, if you try to insert a value, 

COPY enforces everything that insert does.  It's simply a little quicker
than insert due to a different string parsing method and avoiding places
that are for advanced features (subselects, functions, etc.).

A default is still applied if the column has not been provided. 
Likewise, triggers (constraint triggers anyway) still run.

Bumping the start value for an IDENTITY is simple:

CREATE TABLE tab (
 col integer GENERATED ALWAYS AS IDENTITY(START WITH 42)
);

I suppose we'll need a GUC so that GENERATED ALWAYS isn't actually
always -- just usually.

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to