Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ueaBK-00C4L7-78 for pgsql-general@arkaria.postgresql.org; Wed, 23 Jul 2025 14:10:55 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1ueaBH-002UKG-Hd for pgsql-general@arkaria.postgresql.org; Wed, 23 Jul 2025 14:10:51 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ueaBH-002UK7-68 for pgsql-general@lists.postgresql.org; Wed, 23 Jul 2025 14:10:51 +0000 Received: from mail-ed1-x533.google.com ([2a00:1450:4864:20::533]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1ueaBF-000OgH-1P for pgsql-general@postgresql.org; Wed, 23 Jul 2025 14:10:50 +0000 Received: by mail-ed1-x533.google.com with SMTP id 4fb4d7f45d1cf-611f74c1837so12931889a12.3 for ; Wed, 23 Jul 2025 07:10:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec.at; s=google; t=1753279846; x=1753884646; darn=postgresql.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:from:to:cc:subject:date :message-id:reply-to; bh=+rcexGGZJ1NR7HRvCGaugmk3gS8Jpznp+V4p2Amy9+U=; b=JL0AfxK7Q1Eg7J3vMpiOzyVpTo2c8CDOIe7h41giTx2zHJOgs4jgNqfWSLd+EWagpg oYNamymb68dbyWc47uG4LTV0k2+twZ4bfO1LTzvsS5MKC5jSzgyGZK3pZyFyjqOoGg30 2oSn0Ly3h00toOyrsbSQKrnZHhU74jev5Z9PqaDFAlsQw36ozMp0jA4MYBSm8cUtyAd5 SI5XZLwesds9RXbtg1Yr3sRvDQuYtEg9/wZexBMdpWsX9szrwRHNHQ3JwSUswadgpWRU 64CA4quebH2WHqoyKXFWmK7aXFtZbOizmxprHVnkCYKdKsL9SOxlosJZ/nhNBQihAZCH isdw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1753279846; x=1753884646; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:to:from:subject:message-id:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=+rcexGGZJ1NR7HRvCGaugmk3gS8Jpznp+V4p2Amy9+U=; b=pLLZjP7zhfuYHOb7Jj64F/LL6pkjVI1397xfo9vyNPvQ05KJrQEGQvb3ubAUVEq6tT 4mwyboi1pqtLkms0NfPhdsJADojESZxhHSbVjV4NX3LxuHLoQ1+NwaygkloJe/tt0K0e Xqlh44qqARNUGByXE/0yR4FKmnpifzjKlsoDgibnsQotFXH9a/MTsoMUOoOsfFBU3fs9 HQT9U3twxiV1KgHXaLCZt0xMxkcYWMlXdmOyr7fcz7bOUvB04KKJV7h6rPJP3Ecrq/DW i76dfoTC6B3YhRiVPCWIi987hsTB3HQvvTYliO6ldhobqI24ShQCiF3NtoQoZI3wJqrY ePFQ== X-Forwarded-Encrypted: i=1; AJvYcCUg80UfEIrqpqrpgcFlPikf6pEfUAz3YcrvvYGXnxsg5yx3iSlPYSuV/zfewNl+/JiE5pU7HFJkeUv8hYPr@postgresql.org X-Gm-Message-State: AOJu0YwD4ffmIfnTWp8pqEzwFmBR8CGfza2irValkOfz3IocM5x9iCPC iWW358PM+xwLkUGHBXuEn43coW/G2vnNpCpxnCTIog2t56tQK7JLfmHmdDclagK6mkzpdN3Nr50 vkAXZ X-Gm-Gg: ASbGncsUbuO3R4BEY7Rh5nveizJuFEZECcOYnbvCbb9FwQK+k/vk7sIWPnGU22uKXD+ qvu79SFa4YEVCe8tt/ZNFX6IdMeVK7zZu8WUShuqeGMKGU0rV4FZwQppMjEVWifj+aoLw8/LT1P cW1MeBlJiYcCIC07E+QfCU/UsIS8v0/FZv+7xXxPg5BsSjUDiYrkQqNJeP7Pdk9yXMPE2HU7A4g eYJ2xdSJDqQWwbTuBSoDFz2DcKDconvdX60kVnEr42uUF+yK2MRNVPGQ/Mf7rE2udpjwpjboW/P fWCh1ao93Du2FMaLtWzk4Dibrqtc468CPlgQTehkhEKgiC9ZX2cCJEzuQInA62EfBFTAyV9/Umc MMmA0m7kzxSZWWKEU6PSA2TqA0uKptbAe4gVOnqpvc5GQIQk7KWQ= X-Google-Smtp-Source: AGHT+IEDwGujn7hC9arAwJFzEtEfpkD6g061kLZaRbKk6gFzBtG4YcmEE+J+xAFrKp+KdVdKft4W7w== X-Received: by 2002:a05:6402:4310:b0:604:5cae:4031 with SMTP id 4fb4d7f45d1cf-6149b5a7bdfmr3061740a12.28.1753279846130; Wed, 23 Jul 2025 07:10:46 -0700 (PDT) Received: from laurenz.albe-K4N0CV00F97414D ([2001:871:5e:e86d:8078:8faa:e2ff:22f7]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-612c9040d91sm8436599a12.38.2025.07.23.07.10.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 23 Jul 2025 07:10:45 -0700 (PDT) Message-ID: <0af232bff681af8f34fd92ceb4d5c635e11815cb.camel@cybertec.at> Subject: Re: Is there any limit on the number of rows to import using copy command From: Laurenz Albe To: "sivapostgres@yahoo.com" , Pgsql-general Date: Wed, 23 Jul 2025 16:10:44 +0200 In-Reply-To: <959901171.1916220.1753271729336@mail.yahoo.com> References: <1453510076.1900935.1753260637232.ref@mail.yahoo.com> <1453510076.1900935.1753260637232@mail.yahoo.com> <959901171.1916220.1753271729336@mail.yahoo.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.56.2 (3.56.2-1.fc42) MIME-Version: 1.0 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, 2025-07-23 at 11:55 +0000, sivapostgres@yahoo.com wrote: > 1.=C2=A0 I tried running Copy From command from PGAdmin.=C2=A0=C2=A0 > 2.=C2=A0 I ran pg_stat_activity also in another tab [ PGAdmin ]. >=20 > What I observed, > 1.=C2=A0 In about 2 min, in the Dashboard of PGAdmin, the colour changed = to Orange for that particular pid. > 2.=C2=A0 After few seconds, the colour again changed to Red.=C2=A0 =C2=A0 > 3.=C2=A0 The stat column in both Dashboard and pg_stat_activity.state sho= ws 'active'. > 4.=C2=A0 No messages relevant to this pid in postgres' log files > 5.=C2=A0 CPU usage is normal, hovering around 36% overall, 15-18% for pos= tgresql server, from the beginning and even after 3 min. > 6.=C2=A0 We didn't run any other application in that machine.=C2=A0=C2=A0 > 7.=C2=A0 Unique Index is there in table2 which will return only one row f= or that Select Count(*) query. > 8.=C2=A0 No record is there in the target table when transfer started.=C2= =A0 This transfer is the first batch for that particular table. > 9.=C2=A0 Once color turned into Red, I could cancel the query execuion in= PGAdmin, which immediately stops the execution. > 10. I could not see any locks or blocking pids. As far as I know, red in pgAdmin (I don't use it) *is* the indication for a= wait event. So look again what the columns "wait_event_type" and "wait_event" in "pg_st= at_activity" show. Yours, Laurenz Albe