Re: COPY blocking \dt+?

From: David Rowley <dgrowleyml(at)gmail(dot)com>
To: pinker <pinker(at)onet(dot)eu>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: COPY blocking \dt+?
Date: 2020-05-05 01:31:38
Message-ID: CAApHDvpUfigaNAOVaFeVPfWxfbRFsVwA7VoRezMZABG9Y_OZoQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, 5 May 2020 at 13:05, pinker <pinker(at)onet(dot)eu> wrote:
> I'm running standard pgbench and what's kinda strange copy pgbench_accounts
> from stdin is blocking my other query which is \dt+.
> Does copy hold any exclusive lock or there is something wrong with my
> system?

COPY does not. However, pgbench does TRUNCATE the tables before doing
the COPY, so that'll be most likely what's causing your query to get
blocked.

David

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message pinker 2020-05-05 02:50:26 Re: COPY blocking \dt+?
Previous Message Jerry Sievers 2020-05-05 01:17:32 Re: Temporary table has become problematically persistent