Re: [HACKERS] patch: function xmltable

2017-01-19 Thread Alvaro Herrera
Pavel Stehule wrote: > Hi > > New update - rebase after yesterday changes. > > What you want to change? I think the problem might come from the still pending patch on that series, which Andres posted in https://www.postgresql.org/message-id/20170118221154.aldebi7yyjvds...@alap3.anarazel.de As fa

Re: [HACKERS] pg_hba_file_settings view patch

2017-01-19 Thread Michael Paquier
On Thu, Jan 19, 2017 at 9:28 PM, Ashutosh Bapat wrote: > On Thu, Jan 19, 2017 at 1:26 PM, Michael Paquier > wrote: >> On Thu, Jan 19, 2017 at 4:25 PM, Haribabu Kommi >> wrote: >>> Added the cleanup mechanism. But the tokenize_file() function call >>> present in many places, But in one flow still

Re: [HACKERS] pg_hba_file_settings view patch

2017-01-19 Thread Ashutosh Bapat
On Thu, Jan 19, 2017 at 1:26 PM, Michael Paquier wrote: > On Thu, Jan 19, 2017 at 4:25 PM, Haribabu Kommi > wrote: >> Added the cleanup mechanism. But the tokenize_file() function call >> present in many places, But in one flow still it is possible to have >> file descriptor leak because of pg_hb

[HACKERS] How to extract bytes from a bit/bit(n) Datum pointer?

2017-01-19 Thread valeriof
Hi, This may come from my lack of experience with Postgres, but I'm trying to extract the byte portion of a Datum that is of type VarBit - bit/bit(n). I see that the Datum pointer contains the value content of the bytes (after a few bytes for the header) but I would need to point to the actual val

Re: [HACKERS] Causal reads take II

2017-01-19 Thread Thomas Munro
On Thu, Jan 19, 2017 at 8:11 PM, Ants Aasma wrote: > On Tue, Jan 3, 2017 at 3:43 AM, Thomas Munro > wrote: >> Long term, I think it would be pretty cool if we could develop a set >> of features that give you distributed sequential consistency on top of >> streaming replication. Something like (t

Re: [HACKERS] Parallel Index-only scan

2017-01-19 Thread Rafia Sabih
On Fri, Jan 13, 2017 at 2:19 PM, Rafia Sabih wrote: > On Thu, Jan 12, 2017 at 5:39 PM, Rahila Syed wrote: >> Hello, >> >> On applying the patch on latest master branch and running regression tests >> following failure occurs. >> I applied it on latest parallel index scan patches as given in the l

Re: [HACKERS] PoC: Grouped base relation

2017-01-19 Thread Antonin Houska
Antonin Houska wrote: Well, the following one does not seem to be a typical example. I could generate the plan, but now I think that the aggregation push down does not in general decrease the number of groups the final aggregation has to process. Maybe I just hit planner limitation to estimate th

Re: [HACKERS] parallelize queries containing subplans

2017-01-19 Thread Kuntal Ghosh
On Thu, Jan 19, 2017 at 4:51 PM, Dilip Kumar wrote: > On Thu, Jan 19, 2017 at 3:05 PM, Dilip Kumar wrote: >> During debugging I found that subplan created for below part of the >> query is parallel_unsafe, Is it a problem or there is some explanation >> of why it's not parallel_safe, > > Okay, so

Re: [HACKERS] pageinspect: Hash index support

2017-01-19 Thread Ashutosh Sharma
Hi, I got some 'trailing whitespace' error (shown below) when git applying v7 patch attached upthread. I have corrected the same and also ran pgindent on a new file 'hashfuncs.c' added as a part of this project. Attached is the updated v8 patch. 0001-Add-support-for-hash-index-in-pageinspect-cont

Re: [HACKERS] Vacuum: allow usage of more than 1GB of work mem

2017-01-19 Thread Claudio Freire
On Thu, Jan 19, 2017 at 6:33 AM, Anastasia Lubennikova wrote: > 28.12.2016 23:43, Claudio Freire: > > Attached v4 patches with the requested fixes. > > > Sorry for being late, but the tests took a lot of time. I know. Takes me several days to run my test scripts once. > create table t1 as select

Re: [HACKERS] Declarative partitioning - another take

2017-01-19 Thread Amit Langote
On 2017/01/19 14:15, Amit Langote wrote: > So, here are all the patches I posted to date (and one new at the bottom) > for reported and unreported bugs, excluding the one involving > BulkInsertState for which you replied in a new thread. > > I'll describe the attached patches in brief: Sorry, I f

Re: [HACKERS] PoC: Grouped base relation

2017-01-19 Thread Antonin Houska
Tomas Vondra wrote: > On 01/17/2017 08:05 PM, Antonin Houska wrote: > > Tomas Vondra wrote: > > > > > >> Another thing is that in my experience most queries do joins on foreign > >> keys > >> (so the PK side is unique by definition), so the benefit on practical > >> examples > >> is likely muc

Re: [HACKERS] parallelize queries containing subplans

2017-01-19 Thread Dilip Kumar
On Thu, Jan 19, 2017 at 3:05 PM, Dilip Kumar wrote: > During debugging I found that subplan created for below part of the > query is parallel_unsafe, Is it a problem or there is some explanation > of why it's not parallel_safe, Okay, so basically we don't have any mechanism to perform parallel sc

Re: [HACKERS] RustgreSQL

2017-01-19 Thread Ewan Higgs
> It seems someone tried (perhaps ran out of steam, unfortunately): > * Postgres extensions written in Rust * > https://github.com/thehydroimpulse/postgres-extension.rs There is another effort which looks active and promising: (R)ust (P)ost(g)res FFI https://github.com/posix4e/rpgffi This is

Re: [HACKERS] parallelize queries containing subplans

2017-01-19 Thread Kuntal Ghosh
On Thu, Jan 19, 2017 at 3:19 PM, Kuntal Ghosh wrote: > Since Param is not parallel_safe till now, the SubPlan is also not > parallel_safe. This is why CTE subplans will not be pushed under > Gather. Specifically, Params which are generated using generate_new_param() are not parallel_safe. In the p

Re: [HACKERS] parallelize queries containing subplans

2017-01-19 Thread Kuntal Ghosh
On Thu, Jan 19, 2017 at 3:05 PM, Dilip Kumar wrote: > @@ -1213,6 +1216,7 @@ SS_process_ctes(PlannerInfo *root) > &splan->firstColCollation); > splan->useHashTable = false; > splan->unknownEqFalse = false; > + splan->parallel_safe = best_path->parallel_safe; > > I noticed that if path for C

Re: [HACKERS] [BUGS] Bug in Physical Replication Slots (at least 9.5)?

2017-01-19 Thread Kyotaro HORIGUCHI
Hello, At Wed, 18 Jan 2017 12:34:51 +0900, Michael Paquier wrote in > On Tue, Jan 17, 2017 at 7:36 PM, Kyotaro HORIGUCHI > wrote: > > I managed to reproduce this. A little tweak as the first patch > > lets the standby to suicide as soon as walreceiver sees a > > contrecord at the beginning of

Re: [HACKERS] parallelize queries containing subplans

2017-01-19 Thread Dilip Kumar
On Mon, Jan 16, 2017 at 9:13 PM, Amit Kapila wrote: > > After commit-ab1f0c8, this patch needs a rebase. Attached find > rebased version of the patch. > > Thanks to Kuntal for informing me offlist that this patch needs rebase. In this patch, I have observed some changes while creating subplan fo

Re: [HACKERS] Vacuum: allow usage of more than 1GB of work mem

2017-01-19 Thread Anastasia Lubennikova
28.12.2016 23:43, Claudio Freire: Attached v4 patches with the requested fixes. Sorry for being late, but the tests took a lot of time. create table t1 as select i, md5(random()::text) from generate_series(0,4) as i; create index md5_idx ON t1(md5); update t1 set md5 = md5((random()

Re: [HACKERS] Parallel Index Scans

2017-01-19 Thread Amit Kapila
On Thu, Jan 19, 2017 at 12:28 AM, Robert Haas wrote: > On Mon, Jan 16, 2017 at 7:11 AM, Amit Kapila wrote: >> Fixed. > > With respect to the second patch > (parallel_index_opt_exec_support_v4.patch), I'm hoping it can use the > new function from Dilip's bitmap heap scan patch set. See commit > 7

Re: [HACKERS] Parallel Index Scans

2017-01-19 Thread Amit Kapila
On Wed, Jan 18, 2017 at 6:25 AM, Haribabu Kommi wrote: > > > On Mon, Jan 16, 2017 at 11:11 PM, Amit Kapila > wrote: >> >> >> Changed as per suggestion. >> >> >> I have also rebased the optimizer/executor support patch >> (parallel_index_opt_exec_support_v4.patch) and added a test case in >> it. >

Re: [HACKERS] Parallel Index Scans

2017-01-19 Thread Amit Kapila
On Tue, Jan 17, 2017 at 11:27 PM, Robert Haas wrote: > On Mon, Jan 16, 2017 at 7:11 AM, Amit Kapila wrote: >> Fixed. > > Thanks for the update. Some more comments: > > It shouldn't be necessary for MultiExecBitmapIndexScan to modify the > IndexScanDesc. That seems really broken. If a parallel

Re: [HACKERS] Password identifiers, protocol aging and SCRAM protocol

2017-01-19 Thread Simon Riggs
On 19 January 2017 at 06:32, Noah Misch wrote: > On Wed, Jan 18, 2017 at 02:30:38PM +0900, Michael Paquier wrote: >> On Wed, Jan 18, 2017 at 2:23 PM, Noah Misch wrote: >> > The latest versions document this precisely, but I agree with Peter's >> > concern >> > about plain "scram". Suppose it's

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-01-19 Thread Masahiko Sawada
On Thu, Jan 19, 2017 at 4:04 PM, vinayak wrote: > > On 2017/01/16 17:35, Masahiko Sawada wrote: >> >> On Fri, Jan 13, 2017 at 3:48 PM, Masahiko Sawada >> wrote: >>> >>> On Fri, Jan 13, 2017 at 3:20 PM, Ashutosh Bapat >>> wrote: > > Long time passed since original patch proposed by Ashuto

Re: [HACKERS] Logical replication existing data copy

2017-01-19 Thread Erik Rijkers
On 2017-01-18 20:45, Petr Jelinek wrote: AFAICS you should always get error from that test after you enable the Ah tes, you were right, of course; I had assumed the earlier mentioned CREATE SUBSCRIPTION ... [ WITH (COPY DATA | NOCOPY DATA) ] but that syntax wasn't implemented, I now understan

<    1   2