Re: proposal: possibility to read dumped table's name from file

2020-07-26 Thread Pavel Stehule
ne 26. 7. 2020 v 21:10 odesílatel Justin Pryzby napsal: > On Sat, Jul 25, 2020 at 06:56:31PM +0530, vignesh C wrote: > > On Tue, Jul 14, 2020 at 12:03 PM Pavel Stehule > wrote: > > >> I meant can this: > > >> printf(_(" --filter=FILENAMEread object name filter > > >> expressions

Re: proposal: possibility to read dumped table's name from file

2020-07-26 Thread Pavel Stehule
so 25. 7. 2020 v 15:26 odesílatel vignesh C napsal: > On Tue, Jul 14, 2020 at 12:03 PM Pavel Stehule > wrote: > >> I meant can this: > >> printf(_(" --filter=FILENAMEread object name filter > >> expressions from file\n")); > >> be changed to: > >> printf(_(" --filter=FILENAME

Re: Parallel worker hangs while handling errors.

2020-07-26 Thread Bharath Rupireddy
On Sat, Jul 25, 2020 at 7:02 AM vignesh C wrote: > > I have made slight changes on top of the patch to remove duplicate > code, attached v3 patch for the same. > The parallel worker hang issue gets resolved, make check & make > check-world passes. > Having a function to unblock selective signals

Re: recovering from "found xmin ... from before relfrozenxid ..."

2020-07-26 Thread Ashutosh Sharma
Hi, Thanks for sharing your thoughts. Please find my comments inline below: > > I think here we should report that we haven't done what was asked. > + /* Nothing to do if the itemid is unused or > already dead. */ > + if (!ItemIdIsUsed(itemid) ||

Re: new heapcheck contrib module

2020-07-26 Thread Amul Sul
On Tue, Jul 21, 2020 at 2:32 AM Mark Dilger wrote: > [] > > > > + StaticAssertStmt(InvalidOffsetNumber + 1 == > > FirstOffsetNumber, > > +"InvalidOffsetNumber > > increments to FirstOffsetNumber"); > > > > If you are going to rely

Re: Loaded footgun open_datasync on Windows

2020-07-26 Thread Michael Paquier
On Thu, Jul 23, 2020 at 01:05:04PM -0400, Jeff Janes wrote: > I have noticed this before, but since it wasn't a production machine I just > shrugged it off as being a hazard of using consumer-grade stuff; it didn't > seem to be worth investigating further. The most direct and non-invasive way to

Re: Allows Extend Protocol support CURSOR_OPT_HOLD with prepared stmt.

2020-07-26 Thread Andy Fan
> > > 2. Currently I want to add a new GUC parameter, if set it to true, server > will > create a holdable portal, or else nothing changed. Then let the user set > it to true in the above case and reset it to false afterward. Is there > any issue > with this method? > > I forget to say in this

Allows Extend Protocol support CURSOR_OPT_HOLD with prepared stmt.

2020-07-26 Thread Andy Fan
I have a user case like this: rs = prepared_stmt.execute(1); while(rs.next()) { // do something with the result and commit the transaction. conn.commit(); } The driver used the extended protocol in this case. It works like this: 1). Parse -> PreparedStmt. 2). Bind -> Bind the prepared

Re: INSERT INTO SELECT, Why Parallelism is not selected?

2020-07-26 Thread Amit Kapila
On Sun, Jul 26, 2020 at 4:54 PM Amit Kapila wrote: > > On Sat, Jul 25, 2020 at 8:42 PM Tom Lane wrote: > > > > No, "git diff --check" doesn't help. I have tried pgindent but that > also doesn't help neither was I expecting it to help. I am still not > able to figure out how I goofed up this

Re: HashAgg's batching counter starts at 0, but Hash's starts at 1.

2020-07-26 Thread Justin Pryzby
On Mon, Jul 27, 2020 at 10:48:45AM +1200, David Rowley wrote: > On Wed, 1 Jul 2020 at 18:46, Jeff Davis wrote: > > > > On Tue, Jun 30, 2020, 7:04 PM David Rowley wrote: > >> > >> Does anyone have any objections to that being changed? > > > > That's OK with me. By the way, I'm on vacation and

Re: Fast DSM segments

2020-07-26 Thread Thomas Munro
On Sat, Jun 20, 2020 at 7:17 AM Andres Freund wrote: > On 2020-06-19 17:42:41 +1200, Thomas Munro wrote: > > On Thu, Jun 18, 2020 at 6:05 PM Thomas Munro wrote: > > > Here's a version that adds some documentation. > > > > I jumped on a dual socket machine with 36 cores/72 threads and 144GB > >

Re: [PATCH] Performance Improvement For Copy From Binary Files

2020-07-26 Thread Amit Langote
On Sun, Jul 26, 2020 at 6:06 AM Tom Lane wrote: > Amit Langote writes: > > [ v7-0001-Improve-performance-of-binary-COPY-FROM-with-buff.patch ] > > Pushed with cosmetic changes. Thanks for that. > I'd always supposed that stdio does enough internal buffering that short > fread()s shouldn't be

Re: handle a ECPG_bytea typo

2020-07-26 Thread Michael Paquier
On Sat, Jul 25, 2020 at 06:17:42PM +0900, Michael Paquier wrote: > ECPGset_noind_null() and ECPGis_noind_null() in misc.c show that > ECPGgeneric_bytea is attached to ECPGt_bytea. The two structures may > be the same now, but if a bug fix or a code change involves a change > in the structure

Re: Parallel bitmap index scan

2020-07-26 Thread Dilip Kumar
On Mon, 27 Jul 2020 at 3:48 AM, Thomas Munro wrote: > On Mon, Jul 27, 2020 at 1:58 AM Dilip Kumar wrote: > > On Sun, Jul 26, 2020 at 6:42 PM Dilip Kumar > wrote: > > > > > > I would like to propose a patch for enabling the parallelism for the > > > bitmap index scan path. > >

Re: hashagg slowdown due to spill changes

2020-07-26 Thread Jeff Davis
On Sat, 2020-07-25 at 15:08 -0700, Peter Geoghegan wrote: > I find that Andres original "SELECT cat, count(*) FROM > fewgroups_many_rows GROUP BY 1;" test case is noticeably improved by > the patch. Without the patch, v13 takes ~11.46 seconds. With the > patch, it takes only ~10.64 seconds. I saw

Re: HashAgg's batching counter starts at 0, but Hash's starts at 1.

2020-07-26 Thread David Rowley
On Wed, 1 Jul 2020 at 18:46, Jeff Davis wrote: > > On Tue, Jun 30, 2020, 7:04 PM David Rowley wrote: >> >> Does anyone have any objections to that being changed? > > That's OK with me. By the way, I'm on vacation and will catch up on these > HashAgg threads next week. (Adding Justin as I know

Re: Parallel bitmap index scan

2020-07-26 Thread Thomas Munro
On Mon, Jul 27, 2020 at 1:58 AM Dilip Kumar wrote: > On Sun, Jul 26, 2020 at 6:42 PM Dilip Kumar wrote: > > > > I would like to propose a patch for enabling the parallelism for the > > bitmap index scan path. Workers Planned: 4 -> Parallel Bitmap Heap Scan on

Re: proposal: possibility to read dumped table's name from file

2020-07-26 Thread Justin Pryzby
On Sat, Jul 25, 2020 at 06:56:31PM +0530, vignesh C wrote: > On Tue, Jul 14, 2020 at 12:03 PM Pavel Stehule > wrote: > >> I meant can this: > >> printf(_(" --filter=FILENAMEread object name filter > >> expressions from file\n")); > >> be changed to: > >> printf(_("

Re: expose parallel leader in CSV and log_line_prefix

2020-07-26 Thread Justin Pryzby
On Sun, Jul 26, 2020 at 04:42:06PM +0900, Michael Paquier wrote: > On Thu, Jul 23, 2020 at 09:52:14AM +0900, Michael Paquier wrote: > > Sounds fine to me. Thanks. > > > > Do others have any objections with this wording? > > I have used the wording suggested by Alvaro, and applied the patch >

Re: Default setting for enable_hashagg_disk

2020-07-26 Thread Tomas Vondra
On Sat, Jul 25, 2020 at 05:13:00PM -0700, Peter Geoghegan wrote: On Sat, Jul 25, 2020 at 5:05 PM Tomas Vondra wrote: I'm not sure what you mean by "reported memory usage doesn't reflect the space used for transition state"? Surely it does include that, we've built the memory accounting stuff

Re: recovering from "found xmin ... from before relfrozenxid ..."

2020-07-26 Thread Andrey M. Borodin
> 24 июля 2020 г., в 14:05, Ashutosh Sharma написал(а): > > Attached is the patch that adds heap_force_kill(regclass, tid[]) and > heap_force_freeze(regclass, tid[]) functions which Robert mentioned in the > first email in this thread. The patch basically adds an extension named >

Re: Making CASE error handling less surprising

2020-07-26 Thread Chris Travers
On Fri, Jul 24, 2020 at 7:18 PM Tom Lane wrote: > Robert Haas writes: > > Like Pavel, and I think implicitly Dagfinn and Andres, I'm not sure I > > believe this. Pavel's example is a good one. The leakproof exception > > helps, but it doesn't cover everything. Users I've encountered throw > >

Re: Parallel bitmap index scan

2020-07-26 Thread Dilip Kumar
On Sun, Jul 26, 2020 at 6:42 PM Dilip Kumar wrote: > > I would like to propose a patch for enabling the parallelism for the > bitmap index scan path. > > Background: > Currently, we support only a parallel bitmap heap scan path. Therein, > the underlying bitmap index scan is done by a single

Parallel bitmap index scan

2020-07-26 Thread Dilip Kumar
I would like to propose a patch for enabling the parallelism for the bitmap index scan path. Background: Currently, we support only a parallel bitmap heap scan path. Therein, the underlying bitmap index scan is done by a single worker called the leader. The leader creates a bitmap in shared

Re: INSERT INTO SELECT, Why Parallelism is not selected?

2020-07-26 Thread Amit Kapila
On Sat, Jul 25, 2020 at 8:42 PM Tom Lane wrote: > > Amit Kapila writes: > > On Fri, Jul 24, 2020 at 7:36 PM Tom Lane wrote: > >> Yeah, the proposed comment changes don't actually add much. Also > >> please try to avoid inserting non-ASCII into the source code; > >> at least in my mail reader,

Re: Difference for Binary format vs Text format for client-server communication

2020-07-26 Thread Andy Fan
On Sun, Jul 26, 2020 at 1:49 AM Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > On 2020-07-16 18:52, Andy Fan wrote: > > The reason I ask this is because I have a task to make numeric output > > similar to oracle. > > > > Oracle: > > > > SQL> select 2 / 1.0 from dual; > > > >

Re: Parallel Seq Scan vs kernel read ahead

2020-07-26 Thread David Rowley
On Wed, 15 Jul 2020 at 12:24, David Rowley wrote: > If we've not seen any performance regressions within 1 week, then I > propose that we (pending final review) push this to allow wider > testing. It seems we're early enough in the PG14 cycle that there's a > large window of time for us to do

Re: expose parallel leader in CSV and log_line_prefix

2020-07-26 Thread Michael Paquier
On Thu, Jul 23, 2020 at 09:52:14AM +0900, Michael Paquier wrote: > Sounds fine to me. Thanks. > > Do others have any objections with this wording? I have used the wording suggested by Alvaro, and applied the patch down to 13. Now let's see about the original item of this thread.. -- Michael

Re: OpenSSL randomness seeding

2020-07-26 Thread Michael Paquier
On Wed, Jul 22, 2020 at 11:31:38PM +0200, Daniel Gustafsson wrote: > Thanks for picking it up! For the archives, the patch set has been applied as ce4939f and 15e4419 on HEAD. Thanks, Noah. > That's a good question. I believe that if one actually do use RAND_cleanup as > a re-seeding mechanism