On Mon, Nov 4, 2019 at 07:11:48AM +0000, PG Doc comments form wrote:
> The following documentation comment has been logged on the website:
>
> Page: https://www.postgresql.org/docs/12/auto-explain.html
> Description:
>
> Hello,
>
> I had problem with setup auto_explain.log_min_duration for COPY command on
> table with triggers. I set minimum duration to '2s' but no plan logged
> (duration of COPY command was above this limit). I thought that this
> extension not working with COPY command. After some testing I investigate
> that extension is working becouse duration limit is for nested statement
> (query in trigger) not for base statement (COPY) - it will be fine write
> somewere in documentation.
COPY doesn't go through the optimizer, so there is nothing to explain,
e.g.,
test=> EXPLAIN COPY test FROM STDIN;
ERROR: syntax error at or near "COPY"
LINE 1: EXPLAIN COPY test FROM STDIN;
^
--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +