Peter Eisentraut <peter.eisentr...@2ndquadrant.com> writes: > On 2020-08-04 19:36, Konstantin Knizhnik wrote: >> Yes, generated columns are also using implicitly generated sequences. >> So them areĀ very similar with SERIAL/BIGSERIAL columns. This actually >> make we wonder why we can not handle them in the same way in >> CREATE TABLE LIKE.
> The current specification of serial is a parse-time expansion of integer > column, sequence, and column default. Yeah; and note it's actually defined that way in the docs. I'd certainly concede that serial is a legacy feature now that we have identity columns. But, by the same token, its value is in backwards compatibility with old behaviors. Therefore, reimplementing it in a way that isn't 100% backwards compatible seems like entirely the wrong thing to do. On similar grounds, I'd be pretty suspicious of changing LIKE's behaviors around the case. regards, tom lane