Re: BUG #16127: PostgreSQL 12.1 on Windows 2008 R2copy table from ‘large 2GB csv’report “Unknown error”

From: Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>
To: "leiyanliang(at)highgo(dot)com" <leiyanliang(at)highgo(dot)com>
Cc: "pgsql-bugs(at)lists(dot)postgresql(dot)org" <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: BUG #16127: PostgreSQL 12.1 on Windows 2008 R2copy table from ‘large 2GB csv’report “Unknown error”
Date: 2019-11-20 16:19:09
Message-ID: 20191120161909.edfjorf7rnvrox6q@development
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Wed, Nov 20, 2019 at 09:42:49PM +0800, leiyanliang(at)highgo(dot)com wrote:
>Thank you for reply.
>
>I do not think the root cause of this problem is about privilege,and this windows machine is my test machine, only I have access to this machine.
>
>I think this problem is a bug,there are two evidences:
>
>The first evidence :
>
>postgres=# select version();
> version
>------------------------------------------------------------
> PostgreSQL 12.1, compiled by Visual C++ build 1914, 64-bit
>(1 行记录)
>
>
>时间:0.280 ms
>postgres=#
>postgres=#
>postgres=# copy github_events from 'd:\events.csv' csv; ----->>> d:\events.csv( about 316,302,020 Bytes) can copy succussfully!!
>COPY 126245
>时间:19574.819 ms (00:19.575)
>postgres=# \q
>

Ah, I haven't noticed the information about file size in the first post,
as it was buried at the very end :-(

In that case, I think Tom is right it's likely the same issue as [1],
although that starts with a report about issues with 4GB. Maybe that's
due to using different windows version 2008 R2 vs. 2012 R2, though.

It'd be good if you could test the latest patch [2] in that thread.
You'll need to build PostgreSQL on Windows, though - I don't have much
experience with that, but there are wiki pages about doing that either
using Visual Studio [3] or mingw [4].

regards

[1] https://www.postgresql.org/message-id/15858-9572469fd3b73263%40postgresql.org

[2] https://www.postgresql.org/message-id/attachment/103789/0001-WIP-support-for-large-files-on-Win32-v4.patch

[3] https://wiki.postgresql.org/wiki/Working_With_VisualStudio

[4] https://wiki.postgresql.org/wiki/Building_With_MinGW

--
Tomas Vondra http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2019-11-20 18:16:22 Re: ALTER TABLE fails when changing column type due to index with bit_ops opclass
Previous Message Tom Lane 2019-11-20 15:47:41 Re: BUG #16127: PostgreSQL 12.1 on Windows 2008 R2 copy table from ‘large 2GB csv’report “Unknown error”