Re: [HACKERS] calculating an aspect of shared buffer state from a background worker

2014-03-09 Thread Michael Paquier
On Mon, Mar 10, 2014 at 2:09 PM, Robert Berry wrote: > Is there a way to get access to the StrategyControl pointer in the context > of a background worker? StrategyControl is inherent to freelist.c and has no external declaration so you could not have it even if you the BGWORKER_SHMEM_ACCESS flag.

Re: [HACKERS] UNION ALL on partitioned tables won't use indices.

2014-03-09 Thread Kyotaro HORIGUCHI
Hello. Attached is the 2nd version of 'pushdown in UNION ALL on partitioned tables' patch type 1 - fix in equiv-member version. As far as I can see, I have found no problem on the original Tom's patch. I have no annoyance of modifying inh flag and so with this. At Tue, 04 Mar 2014 18:57:56 +090

Re: [HACKERS] Little confusing things about client_min_messages.

2014-03-09 Thread Tomonari Katsumata
Hi Tom, Bruce, Thank you for your response. (2014/03/09 2:12), Tom Lane wrote: > Bruce Momjian writes: >> On Sat, Mar 8, 2014 at 11:31:22AM -0500, Tom Lane wrote: >>> Tomonari Katsumata writes: [ client_min_messages = info is not documented ] > >>> That's intentional, because it's not a us

Re: [HACKERS] [bug fix] pg_ctl always uses the same event source

2014-03-09 Thread Amit Kapila
On Mon, Feb 17, 2014 at 9:17 AM, Amit Kapila wrote: > On Sat, Feb 1, 2014 at 12:31 PM, Amit Kapila wrote: >> I think it's just a very minor coding style thing, so I am marking this >> patch as >> Ready For Committer. > > I could see that this patch has been marked as Needs Review in CF app. > su

Re: [HACKERS] issue log message to suggest VACUUM FULL if a table is nearly empty

2014-03-09 Thread Amit Kapila
On Mon, Mar 10, 2014 at 5:58 AM, Wang, Jing wrote: > Enclosed is the patch to implement the requirement that issue log message to > suggest VACUUM FULL if a table is nearly empty. > > The requirement comes from the Postgresql TODO list. > > [Solution details] > > A check function is added in the f

Re: [HACKERS] [review] PostgreSQL Service on Windows does not start if data directory given is relative path

2014-03-09 Thread Rajeev rastogi
While registering the service for PostgreSQL on windows, we cannot expect user to give absolute path always. So it is required to support relative path as data directory. So this patch will be very useful to handle the same. This patch has been in "Ready for committer" stage for long time. Pleas

[HACKERS] calculating an aspect of shared buffer state from a background worker

2014-03-09 Thread Robert Berry
Dear Hackers -- I'm looking at doing a calculation to determine the number of free buffers available. A n example ratio that is based on some data structures in freelist.c as follows: (StrategyControl->lastFreeBuffer - StrategyControl->firstFreeBuffer) / (double) NBuffers Is there a way to get

Re: [HACKERS] review: psql command copy count tag

2014-03-09 Thread Tom Lane
Rajeev rastogi writes: > This has been in “Ready for committer” stage for long time. Yeah, I started to work on it and got distracted, but was working on it some more yesterday. As submitted, it leaks PGresults, and makes some inconsistent and mostly undocumented changes in the APIs of the p

Re: [HACKERS] review: psql command copy count tag

2014-03-09 Thread Rajeev rastogi
As mentioned by Pavel also, this patch will be very useful, which provides below enhancement: 1. Brings consistency between copy from “stdin” and “file”. 2. Consistent with server side copy statement. 3. Also fixes the issue related to “\copy destination file becomes default

Re: [HACKERS] WIP patch (v2) for updatable security barrier views

2014-03-09 Thread Craig Ringer
I've found an issue with updatable security barrier views. Locking is being pushed down into the subquery. Locking is thus applied before user-supplied quals are, so we potentially lock too many rows. I'm looking into the code now, but in the mean time, here's a demo of the problem: regress=> C

Re: [HACKERS] ALTER TABLE lock strength reduction patch is unsafe

2014-03-09 Thread Vik Fearing
On 03/06/2014 10:47 AM, Simon Riggs wrote: > On 5 March 2014 09:28, Simon Riggs wrote: > >> So that returns us to solving the catalog consistency problem in >> pg_dump and similar applications. > No answer, guys, and time is ticking away here. Sorry, I've accumulated several days of backlog (and

[HACKERS] issue log message to suggest VACUUM FULL if a table is nearly empty

2014-03-09 Thread Wang, Jing
Hi Enclosed is the patch to implement the requirement that issue log message to suggest VACUUM FULL if a table is nearly empty. The requirement comes from the Postgresql TODO list. [Benefit] To find which table is nearly empty and suggest using 'VACUUM FULL' to release the unused disk sp

Re: [HACKERS] Selection of join algorithm.

2014-03-09 Thread Jeff Janes
On Sat, Mar 8, 2014 at 6:18 AM, Ishaya Bhatt wrote: > Hi, > > I am trying to analyze join performance. But I see that even for a table > having 100,000 rows and join attribute as primary key, postgres always > performs hash join. > > Can anyone please tell me under which conditions merge join or

[HACKERS] db_user_namespace a "temporary measure"

2014-03-09 Thread Thom Brown
Hi, I've noticed that "db_user_namespace" has had the following note attached to it since 2002: "This feature is intended as a temporary measure until a complete solution is found. At that time, this option will be removed." It will be 12 years this year since this "temporary measure" was added.

Re: [HACKERS] Regression test errors

2014-03-09 Thread Martín Marqués
OK, noticed how horrible this patch was (thanks for the heads up from Jaime Casanova). This happens when trying to fetch changes one made on a test copy after a day of lots of work back to a git repository: you just make very silly mistakes. Well, now I got the changes right (tested the patch, bec