Search Postgresql Archives

Re: why generated columsn cannot be used in COPY TO?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Luca Ferrari <fluca1978@xxxxxxxxx> writes:
> I'm wondering why in COPY TO (file or program) I cannot use generated
> columns: since I'm pushing data out of the table, why they are not
> allowed?

There's a comment about that in copy.c:

 * We don't include generated columns in the generated full list and we don't
 * allow them to be specified explicitly.  They don't make sense for COPY
 * FROM, but we could possibly allow them for COPY TO.  But this way it's at
 * least ensured that whatever we copy out can be copied back in.

Not sure how convincing that reasoning is, but it was at least
thought about.  I do agree with it as far as the default column
list goes, but maybe we could allow explicit selection of these
columns in COPY TO.

			regards, tom lane





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux