Re: [HACKERS] Partition-wise aggregation/grouping

2017-11-28 Thread Jeevan Chalke
On Tue, Nov 28, 2017 at 12:37 PM, Rajkumar Raghuwanshi < rajkumar.raghuwan...@enterprisedb.com> wrote: > On Thu, Nov 23, 2017 at 6:38 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Let me know if I missed any comment to be fixed. > > Hi, > > I

Re: [HACKERS] Partition-wise aggregation/grouping

2017-11-15 Thread Jeevan Chalke
On Sun, Nov 12, 2017 at 1:59 AM, Konstantin Knizhnik < k.knizh...@postgrespro.ru> wrote: > On 10/27/2017 02:01 PM, Jeevan Chalke wrote: > >> Hi, >> >> Attached new patch-set here. Changes include: >> >> 1. Added separate patch for costing Append node as

Re: [HACKERS] Partition-wise aggregation/grouping

2017-11-15 Thread Jeevan Chalke
On Thu, Nov 2, 2017 at 7:36 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Nov 1, 2017 at 6:20 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Yep. > > But as David reported earlier, if we remove the first part i.e. adding > > cpu_o

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-18 Thread Jeevan Chalke
S OFF)\nSELECT > AVG(t2.c1),SUM(t1.c1) FROM part t1 INNER JOIN part t2 ON (t1.c1 = t2.c1) > GROUP BY t1.c1, t2.c1 HAVING SUM(t1.c1) % 125 = 0 ORDER BY 1,2;") at > postgres.c:1122 > #20 0x008c8dbf in PostgresMain (argc=1, argv=0x1c922a0, > dbname=0x1c92100 "postgres", username=0x1c65298 "edb") at postgres.c:4153 > #21 0x00826703 in BackendRun (port=0x1c8a060) at postmaster.c:4361 > #22 0x00825e71 in BackendStartup (port=0x1c8a060) at > postmaster.c:4033 > #23 0x00822253 in ServerLoop () at postmaster.c:1706 > #24 0x00821b85 in PostmasterMain (argc=3, argv=0x1c631f0) at > postmaster.c:1379 > #25 0x00748d64 in main (argc=3, argv=0x1c631f0) at main.c:228 > > Thanks & Regards, > Rajkumar Raghuwanshi > QMG, EnterpriseDB Corporation > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-19 Thread Jeevan Chalke
On Tue, Jun 19, 2018 at 2:13 PM, Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > > On Mon, Jun 18, 2018 at 9:27 PM, Andres Freund wrote: > >> On 2018-06-18 17:10:12 +0530, Jeevan Chalke wrote: >> > On Mon, Jun 18, 2018 at 5:02 PM, Rajkumar Rag

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-27 Thread Jeevan Chalke
ning why it's correct, because there isn't anything > obvious in set_append_rel_pathlist that keeps IS_DUMMY_REL() from > being true for every child. > > -- > Robert Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-11 Thread Jeevan Chalke
ot recursed into next level. > Will work on it and submit changes in the next patch-set. > Attached new set of patches adding this. Only patch 0007 (main patch) and 0008 (testcase patch) has changed. > Please have a look and let me know if I missed any. Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v10.tar.gz Description: GNU Zip compressed data

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-16 Thread Jeevan Chalke
On Tue, Jan 16, 2018 at 3:41 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Jan 11, 2018 at 6:00 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Attached new set of patches adding this. Only patch 0007 (main patch) > and > >

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-02 Thread Jeevan Chalke
On Fri, Feb 2, 2018 at 1:41 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Feb 1, 2018 at 8:59 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > I wrote a patch for this (on current HEAD) and attached separately here. > > Please have a look.

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-01 Thread Jeevan Chalke
On Thu, Feb 1, 2018 at 1:11 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Mon, Jan 29, 2018 at 3:42 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Attached new patch set and rebased it on latest HEAD. > > I strongly dislike add_single_path_to

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-29 Thread Jeevan Chalke
On Sat, Jan 27, 2018 at 1:35 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Jan 18, 2018 at 8:55 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Attached patch with other review points fixed. > > Committed 0001 and 0002 together, with some

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-13 Thread Jeevan Chalke
> Partitioning info: > Total 10 partitions on tables - lineitem and orders each with partitioning > key being l_orderkey and o_orderkey respectively. > > Please find the attached file for explain analyse outputs of each of the > reported query. > -- > Regards, > Rafia Sa

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-14 Thread Jeevan Chalke
On Wed, Feb 14, 2018 at 12:17 PM, Rafia Sabih <rafia.sa...@enterprisedb.com> wrote: > On Tue, Feb 13, 2018 at 6:21 PM, Jeevan Chalke < > jeevan.cha...@enterprisedb.com> wrote: > >> >> I see that partition-wise aggregate plan too uses parallel index, am I >>

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-08 Thread Jeevan Chalke
wrote: > On Fri, Feb 2, 2018 at 8:25 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > >> The problem is that create_partition_agg_paths() is doing *exactly* > >> same thing that add_paths_to_grouping_rel() is already doing inside > >> the blocks tha

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-01 Thread Jeevan Chalke
other upper rel kinds. Please have a look. > > Another problem with that structure is its name doesn't mention that the > structure is used only for child upper relations, whereas the code assumes > that > if extra is not present it's a parent upper relation. May be we want to > rename > it to that effect or always use it whether for a parent or a child > relation. > Renamed to OtherUpperPathExtraData. > We may want to rename pathTarget and partialPathTarget as relTarget and > partialRelTarget since those targets are not specific to any path, but > will be > applicable to all the paths created for that rel. > Renamed. These fixes are part of the v9 patchset. Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-01 Thread Jeevan Chalke
rect. Added relevant check which checks for required pathkeys present or not. > > > diff --git a/src/tools/pgindent/typedefs.list > b/src/tools/pgindent/typedefs.list > index b422050..1941468 100644 > --- a/src/tools/pgindent/typedefs.list > +++ b/src/tools/pgindent/typedefs.list > @@ -2345,6 +2345,7 @@ UnlistenStmt > UnresolvedTup > UnresolvedTupData > UpdateStmt > +UpperPathExtraData > UpperRelationKind > UpperUniquePath > UserAuth > > Do we commit this file as part of the feature? > -- > Best Wishes, > Ashutosh Bapat > EnterpriseDB Corporation > The Postgres Database Company > This patchset contains fixes for other review comments too. Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v9.tar.gz Description: GNU Zip compressed data

Re: [HACKERS] Partition-wise aggregation/grouping

2018-01-02 Thread Jeevan Chalke
-> Parallel Seq Scan on pagg_tab_para_p3 > [ ... clipped ... ] > +-- When GROUP BY clause not matches with PARTITION KEY. > +EXPLAIN (COSTS OFF) > +SELECT y, sum(x), avg(x), count(*) FROM pagg_tab_para GROUP BY y > HAVING avg(x) < 12 ORDER BY 1, 2, 3; > +

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-20 Thread Jeevan Chalke
On Tue, Jun 19, 2018 at 7:14 PM, Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > In the reported testcase, parallel_workers is set to 0 for all partition >> (child) relations. Which means partial parallel paths are not possible for >> child rels. However, the

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-21 Thread Jeevan Chalke
On Wed, Jun 20, 2018 at 7:11 PM, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > On Tue, Jun 19, 2018 at 2:13 PM, Jeevan Chalke > wrote: > > > > > > In the reported testcase, parallel_workers is set to 0 for all partition > > (child) relations

Re: Server crashed with TRAP: FailedAssertion("!(parallel_workers > 0)" when partitionwise_aggregate true.

2018-06-21 Thread Jeevan Chalke
Hi, Off-list Ashutosh Bapat has suggested using a flag instead of counting number of dummy rels and then manipulating on it. That will be simple and smoother. I agree with his suggestion and updated my patch accordingly. Thanks -- Jeevan Chalke Technical Architect, Product Development

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-08 Thread Jeevan Chalke
On Thu, Mar 8, 2018 at 7:49 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Mar 8, 2018 at 9:15 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > I am not sure why we don't set reltarget into the grouped_rel too. > > > > But if we do so

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-08 Thread Jeevan Chalke
On Thu, Mar 8, 2018 at 1:15 PM, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > On Wed, Mar 7, 2018 at 8:07 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > Here are some more review comments esp. on > try_partitionwise_grouping() function. B

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-12 Thread Jeevan Chalke
GroupPathExtraData to FDWs through GetForeignUpperPaths(). I > haven't tried it in this patch. > > With this patch there's a failure in partition_aggregation where the > patch is creating paths with MergeAppend with GatherMerge underneath. > I think this is related to the call > add_path

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-12 Thread Jeevan Chalke
it further. > I fixed it. We need to pass is_partial_agg instead of extra->partial_partitionwise_grouping while calling add_paths_to_partial_grouping_rel() in case of parallelism. > With those two things remaining I am posting this patch, so that > Jeevan Chalke can merge this patch

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-01 Thread Jeevan Chalke
t Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v14.tar.gz Description: GNU Zip compressed data

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-13 Thread Jeevan Chalke
< ashutosh.ba...@enterprisedb.com> wrote: > On Mon, Mar 12, 2018 at 7:49 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > > > > > On Mon, Mar 12, 2018 at 6:07 PM, Ashutosh Bapat > > <ashutosh.ba...@enterprisedb.com> wrote: > >> >

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-15 Thread Jeevan Chalke
partitionwise paths, rather if possible we do create them. So inlined with create_grouping_paths() I have renamed it to create_partitionwise_grouping_paths() in attached patch-set. Thanks > -- > Best Wishes, > Ashutosh Bapat > EnterpriseDB Corporation > The Postgres Database Company > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v20.tar.gz Description: application/gzip

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-06 Thread Jeevan Chalke
On Tue, Mar 6, 2018 at 2:29 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Mon, Mar 5, 2018 at 3:56 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > However, to perform Gather or Gather Merge once we have all partial paths > > ready, and t

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-07 Thread Jeevan Chalke
over it. Yes, it removed this block and other few conditions too. > > static PathTarget * > -make_partial_grouping_target(PlannerInfo *root, PathTarget > *grouping_target) > +make_partial_grouping_target(PlannerInfo *root, > + PathTarget *grouping_target, > + Node *havingQual) > This looks like a refactoring change. Should go to one of the refactoring > patches or in a patch of its own. > OK. Refactored into separate patch. Will post a new patchset with these changes included. > > This isn't full review. I will continue reviewing this further. > Sure. > > -- > Best Wishes, > Ashutosh Bapat > EnterpriseDB Corporation > The Postgres Database Company > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-07 Thread Jeevan Chalke
On Wed, Mar 7, 2018 at 1:45 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Tue, Mar 6, 2018 at 5:31 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > This is in-lined with enable_hashagg GUC. Do you think > > enable_partit

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-06 Thread Jeevan Chalke
e refactoring, we can get rid of the last two lines here. I > think we can get rid of this block entirely, but I have not reviewed the > entire > code to confirm that. > > static PathTarget * > -make_partial_grouping_target(PlannerInfo *root, PathTarget > *grouping_target) > +make_partial_grouping_target(PlannerInfo *root, > + PathTarget *grouping_target, > + Node *havingQual) > This looks like a refactoring change. Should go to one of the refactoring > patches or in a patch of its own. > > This isn't full review. I will continue reviewing this further. > > -- > Best Wishes, > Ashutosh Bapat > EnterpriseDB Corporation > The Postgres Database Company > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-14 Thread Jeevan Chalke
On Tue, Mar 13, 2018 at 7:43 PM, Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > Hi, > > The patch-set is complete now. But still, there is a scope of some comment > improvements due to all these refactorings. I will work on it. Also, need > to update few documentat

Re: [sqlsmith] Failed assertion in create_gather_path

2018-04-08 Thread Jeevan Chalke
t; 039eb6e92f, > > only that that's the version he happened to be testing. > > Right. I'm not testing often enough yet to be able to report on commit > granularity :-). I'll try for a less ambiguos wording in future > reports. > > -- Jeevan Chalke Technical Architect, Produc

Re: [HACKERS] Partition-wise aggregation/grouping

2018-04-10 Thread Jeevan Chalke
On Tue, Apr 10, 2018 at 7:30 PM, David Steele <da...@pgmasters.net> wrote: > Hi Jeevan, > > On 4/2/18 10:57 AM, Robert Haas wrote: > > On Thu, Mar 29, 2018 at 9:02 AM, Jeevan Chalke > > <jeevan.cha...@enterprisedb.com> wrote: > >> Yep, I see the risk.

Re: [sqlsmith] Failed assertion in create_gather_path

2018-04-11 Thread Jeevan Chalke
On Tue, Apr 10, 2018 at 11:14 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Tue, Apr 10, 2018 at 2:59 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > I actually wanted to have rel->consider_parallel in the condition (yes, > for > >

Re: [sqlsmith] Failed assertion in create_gather_path

2018-04-10 Thread Jeevan Chalke
On Mon, Apr 9, 2018 at 5:52 PM, Amit Kapila <amit.kapil...@gmail.com> wrote: > On Sun, Apr 8, 2018 at 1:04 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Hi, > > > > At some places, I have observed that we are adding a partial path even > wh

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-27 Thread Jeevan Chalke
On Mon, Mar 26, 2018 at 5:24 PM, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > On Fri, Mar 23, 2018 at 4:35 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > > > Changes related to postgres_fdw which allows pushing aggregate on the

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-27 Thread Jeevan Chalke
On Tue, Mar 27, 2018 at 3:33 AM, Andres Freund <and...@anarazel.de> wrote: > Hi, > > On 2018-03-23 17:01:54 +0530, Jeevan Chalke wrote: > > Attached patch which fixes that. > > Thanks, will push. For the future, I'd be more likely to notice if you > CC me ;) > S

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-29 Thread Jeevan Chalke
eone may use havingQual instead > of remote_conds/local_conds just because its available and then there > is risk of these three lists going out of sync. > Yep, I see the risk. > > -- > Best Wishes, > Ashutosh Bapat > EnterpriseDB Corporation > The Postgres Database Compan

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-29 Thread Jeevan Chalke
On Wed, Mar 28, 2018 at 7:21 PM, Ashutosh Bapat < ashutosh.ba...@enterprisedb.com> wrote: > On Tue, Mar 27, 2018 at 2:43 PM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > > I am not sure on what we should Assetrt here. Note that we end-up here >

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-20 Thread Jeevan Chalke
Let me know if I missed any point to consider while rebasing. -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v21.tar.gz Description: application/gzip

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-22 Thread Jeevan Chalke
On Thu, Mar 22, 2018 at 3:26 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Mar 21, 2018 at 11:33 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Let me try to explain this: > > 1. GROUPING_CAN_PARTITIONWISE_AGG > > 2. extra-

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-22 Thread Jeevan Chalke
. I remember we need this while working on Aggregate PushDown, and in [1] Tom Lane opposed the idea of setting the relids in grouped_rel. If we want to go with this, then I think it should be done as a separate stand-alone patch. [1] https://www.postgresql.org/message-id/CAFjFpRdUz6h6cmFZFYAngmQAX8

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-21 Thread Jeevan Chalke
On Wed, Mar 21, 2018 at 2:04 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Tue, Mar 20, 2018 at 10:46 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > I have added all these three patches in the attached patch-set and > rebased > > my changes

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-23 Thread Jeevan Chalke
On Thu, Mar 22, 2018 at 10:28 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Mar 22, 2018 at 6:15 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Leeks cleaner now. Thanks for refactoring it. > > > > I have merged these chan

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-23 Thread Jeevan Chalke
stable regression run with installcheck having local settings. For example, If I have enabale_hashagg = false locally; I will definitely see failures. ISTM, that I am missing Andres point here. Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-21 Thread Jeevan Chalke
On Wed, Mar 21, 2018 at 7:46 PM, Robert Haas <robertmh...@gmail.com> wrote: > On Wed, Mar 21, 2018 at 8:01 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > >> In the patch as proposed, create_partial_grouping_paths() can get > >> called even if GRO

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-05 Thread Jeevan Chalke
www.enterprisedb.com > The Enterprise PostgreSQL Company > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company partition-wise-agg-v15.tar.gz Description: application/gzip

Re: [HACKERS] Partition-wise aggregation/grouping

2018-03-05 Thread Jeevan Chalke
On Fri, Mar 2, 2018 at 3:22 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Mar 1, 2018 at 5:34 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > Attached new patchset after rebasing my changes over these changes and on > > latest HEAD.

Re: [HACKERS] Partition-wise aggregation/grouping

2018-02-26 Thread Jeevan Chalke
Hi Robert, On Fri, Feb 23, 2018 at 2:53 AM, Robert Haas <robertmh...@gmail.com> wrote: > On Thu, Feb 8, 2018 at 8:05 AM, Jeevan Chalke > <jeevan.cha...@enterprisedb.com> wrote: > > In this attached version, I have rebased my changes over new design of > > partiall

Re: Re: ERROR: Aggref found in non-Agg plan node (introducesd in commit 3bf05e096b9f8375e640c5d7996aa57efd7f240c)

2018-02-27 Thread Jeevan Chalke
On Tue, Feb 27, 2018 at 4:55 PM, Andreas Joseph Krogh <andr...@visena.com> wrote: > På tirsdag 27. februar 2018 kl. 12:16:42, skrev Jeevan Chalke < > jeevan.cha...@enterprisedb.com>: > > Hi, > > On Tue, Feb 27, 2018 at 3:46 PM, Andreas Joseph Krogh <andr...@vi

Re: ERROR: Aggref found in non-Agg plan node (introducesd in commit 3bf05e096b9f8375e640c5d7996aa57efd7f240c)

2018-02-27 Thread Jeevan Chalke
for the same ( https://www.postgresql.org/message-id/CAM2+6=x9kxqol2zqz00e6asbt9z+rfywbomhxj0+8fpaymz...@mail.gmail.com ) Can you please check if that fixes your test-case or not? Thanks > > -- > Andreas Joseph Krogh > ​ > > -- Jeevan Chalke Technical Architect, Produ

cache lookup failed for collation 0

2019-04-11 Thread Jeevan Chalke
code changes done by the said commit and thus the current behavior i.e. cache lookup error, might be the expected one. But if that's the case, I kindly request to please explain why that is expected. Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The

Re: cache lookup failed for collation 0

2019-04-12 Thread Jeevan Chalke
On Thu, Apr 11, 2019 at 10:50 PM Tom Lane wrote: > Jeevan Chalke writes: > > Do you mean, the code in get_collation_isdeterministic() should look like > > something like below? > > > If colloid = InvalidOid then > > return TRUE > > ELSE IF tuple is valid t

Re: cache lookup failed for collation 0

2019-04-14 Thread Jeevan Chalke
On Fri, Apr 12, 2019 at 1:26 PM Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > On 2019-04-11 17:04, Jeevan Chalke wrote: > > The error is coming from get_collation_isdeterministic() when colloid > > passed is 0. I think like we do in get_collation_name(), we sh

Re: cache lookup failed for collation 0

2019-04-11 Thread Jeevan Chalke
On Thu, Apr 11, 2019 at 9:07 PM Tom Lane wrote: > Jeevan Chalke writes: > > Following test-sequence causing an error "cache lookup failed for > collation 0"; > > postgres:5432 [42106]=# create table foobar(a bytea primary key, b int); > > CREATE TABLE

Re: Statistical aggregate functions are not working with partitionwise aggregate

2019-05-03 Thread Jeevan Chalke
; > 0 > (1 row) > postgres=# SELECT regr_avgx(b, a), regr_avgy(b, a) FROM tbl; > regr_avgx | regr_avgy > ---+--- >| > (1 row) > postgres=# SELECT corr(b, a) FROM tbl; > corr > -- > > (1 row) > > Thanks & Regar

Re: block-level incremental backup

2019-07-11 Thread Jeevan Chalke
s We are also working on combining these incremental back-ups with the full backup and for that, we are planning to add a new utility called pg_combinebackup. Will post the details on that later once we have on the same page for taking backup. Thanks -- Jeevan Chalke Technical Architect, Product Devel

Re: block-level incremental backup

2019-08-12 Thread Jeevan Chalke
e not. Perhaps >> something like REFERENCE WAL LOCATION or REFERENCE WAL LOCATION FOR >> INCREMENTAL BACKUP would be clearer. >> > > Agree, how about INCREMENTAL BACKUP REFERENCE WAL LOCATION ? > +1 for INCREMENTAL BACKUP REFERENCE WA. > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: block-level incremental backup

2019-08-12 Thread Jeevan Chalke
On Fri, Aug 9, 2019 at 6:36 PM Robert Haas wrote: > On Wed, Aug 7, 2019 at 5:46 AM Jeevan Chalke > wrote: > > So, do you mean we should just do fread() and fwrite() for the whole > file? > > > > I thought it is better if it was done by the OS itself instead of > r

Re: block-level incremental backup

2019-08-12 Thread Jeevan Chalke
On Mon, Aug 12, 2019 at 5:29 PM Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > > On Fri, Aug 9, 2019 at 11:56 PM Jeevan Ladhe < > jeevan.la...@enterprisedb.com> wrote: > >> Hi Robert, >> >> On Fri, Aug 9, 2019 at 6:40 PM Robert Haas wrote:

Re: block-level incremental backup

2019-07-29 Thread Jeevan Chalke
ng and other issues as I explained earlier. I am almost done writing the patch for pg_combinebackup and will post soon. > > -- > Robert Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > > > Thanks -- Jeevan Chalke Technical Archite

Re: block-level incremental backup

2019-08-16 Thread Jeevan Chalke
Regards, > Vignesh > EnterpriseDB: http://www.enterprisedb.com > Attached new sets of patches with refactoring done separately. Incremental backup patch became small now and hopefully more readable than the first version. -- Jeevan Chalke Technical Architect, Product Development Ente

Re: basebackup.c's sendFile() ignores read errors

2019-08-30 Thread Jeevan Chalke
t; + * zeros. > + */ > + if (feof(fp)) > > The if block does not do the truncation right away, so I think the comment > above can be reworded to explain why we reset cnt? > Fixed both comments in the attached patch. -- Jeevan Chalke Technical Architect, Product Development Enter

Re: basebackup.c's sendFile() ignores read errors

2019-08-28 Thread Jeevan Chalke
over the patch and let me know your views. > > -- > Robert Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > > > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company diff -

Re: basebackup.c's sendFile() ignores read errors

2019-09-06 Thread Jeevan Chalke
t; EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company diff --git a/src/backend/replication/basebackup.c b/src/backend/replication/basebac

Re: block-level incremental backup

2019-09-12 Thread Jeevan Chalke
. I tried looking for any other DDL doing similar stuff like creating a new page with existing LSN. But I could not find any other commands than CREATE DATABASE and ALTER DATABASE .. SET TABLESPACE. Suggestions/thoughts? -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
nged this per your suggestion. > > -- > Regards, > Dilip Kumar > EnterpriseDB: http://www.enterprisedb.com > -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
Hi, Attached new set of patches adding support for the tablespace handling. This patchset also fixes the issues reported by Vignesh, Robert, Jeevan Ladhe, and Dilip Kumar. Please have a look and let me know if I missed any comments to account. Thanks -- Jeevan Chalke Technical Architect

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
s completed. > Yes. > Comment: > We can add a readme file with all the details regarding incremental > backup and combine backup. > Will have a look. > > Regards, > Vignesh > EnterpriseDB: http://www.enterprisedb.com > Thanks -- Jeevan Chalke Technical Architect, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
On Tue, Aug 27, 2019 at 11:59 PM Robert Haas wrote: > On Fri, Aug 16, 2019 at 6:23 AM Jeevan Chalke > wrote: > > [ patches ] > > Reviewing 0002 and 0003: > > - Commit message for 0003 claims magic number and checksum are 0, but > that (fortunately) doesn't seem to be

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
On Tue, Sep 3, 2019 at 12:11 PM Dilip Kumar wrote: > On Fri, Aug 16, 2019 at 3:54 PM Jeevan Chalke > wrote: > > > 0003: > +/* > + * When to send the whole file, % blocks modified (90%) > + */ > +#define WHOLE_FILE_THRESHOLD 0.9 > > How this threshold

Re: block-level incremental backup

2019-09-09 Thread Jeevan Chalke
r documentation. I think we > should clarify it at both the places. > Added in doc. > > I think scan_directory() should be rather renamed as do_combinebackup(). > I am not sure about this renaming. scan_directory() is called recursively to scan each sub-directories too. I

Re: block-level incremental backup

2019-08-07 Thread Jeevan Chalke
e file? I thought it is better if it was done by the OS itself instead of reading 1GB into the memory and writing the same to the file. > -- > Robert Haas > EnterpriseDB: http://www.enterprisedb.com > The Enterprise PostgreSQL Company > -- Jeevan Chalke Technical Architect,

Re: block-level incremental backup

2019-08-01 Thread Jeevan Chalke
On Tue, Jul 30, 2019 at 9:39 AM Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > > > I am almost done writing the patch for pg_combinebackup and will post soon. > Attached patch which implements the pg_combinebackup utility used to combine full basebackup with on

Re: block-level incremental backup

2019-07-17 Thread Jeevan Chalke
On Wed, Jul 17, 2019 at 7:38 PM Ibrar Ahmed wrote: > > > On Wed, Jul 17, 2019 at 6:43 PM Jeevan Chalke < > jeevan.cha...@enterprisedb.com> wrote: > >> On Wed, Jul 17, 2019 at 2:15 PM Ibrar Ahmed >> wrote: >> >>> >>> At what stage y

Re: block-level incremental backup

2019-07-17 Thread Jeevan Chalke
us, the last incremental backup will have the final WAL files which will be copied as-is in the combined full-backup and they will get apply automatically if that the data directory is used to start the server. > -- > Ibrar Ahmed > -- Jeevan Chalke Technical Architect, Product Dev

Re: block-level incremental backup

2019-07-16 Thread Jeevan Chalke
On Thu, Jul 11, 2019 at 5:00 PM Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > Hi Anastasia, > > On Wed, Jul 10, 2019 at 11:47 PM Anastasia Lubennikova < > a.lubennik...@postgrespro.ru> wrote: > >> 23.04.2019 14:08, Anastasia Lubennikova wrote: >&

Re: backup manifests

2019-09-30 Thread Jeevan Chalke
Broken()) > > Yes I too obeserved this warning. > pg_gmtime can fail in case of malloc failure: > + /* > + * Convert time to a string. Since it's not clear what time zone to use > + * and since time zone definitions can change, possibly causing confusion, > + * use GMT always

Re: backup manifests

2019-11-21 Thread Jeevan Chalke
entry in the manifest as manifest entry gives mtime from server file whereas the same file in the backup will have different mtime. But adding a few comments there will be good. 8. +charmdate[24]; should be mtime instead? Thanks -- Jeevan Chalke Associate Database Architect & Team Lead, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: backup manifests

2019-11-21 Thread Jeevan Chalke
st-with-checksums option then too I see that checksum is calculated for backup_manifest file itself. Is that intentional or missed? I think we should omit that too if this option is not provided. 6. Is it possible to get only a backup manifest from the server? A client like pg_basebackup can the

Re: backup manifests

2019-12-08 Thread Jeevan Chalke
to all the required function, will it better to pass the struct variable instead? A struct may have members like, "StringInfo manifest" in it, checksum type (manifest_checksums), checksum label, etc. Thanks -- Jeevan Chalke Associate Database Architect & Team Lead, Product Development EnterpriseDB Corporation The Enterprise PostgreSQL Company

Re: backup manifests

2019-12-10 Thread Jeevan Chalke
On Tue, Dec 10, 2019 at 3:29 PM Rushabh Lathia wrote: > > Attaching another version of 0002 patch, as my collogue Jeevan Chalke > pointed > few indentation problem in 0002 patch which I sent earlier. Fixed the > same in > the latest patch. > I had a look over the new pa

Re: WIP/PoC for parallel backup

2019-10-18 Thread Jeevan Chalke
a new option for that? 6. It will be good if we have some comments explaining what the function is actually doing in its prologue. For functions like: GetBackupFilesList() ReceiveFiles() create_workers_and_fetch() Thanks > > Thanks, > > -- > Asif Rehman > Highgo Software (Canada

Re: WIP/PoC for parallel backup

2019-11-27 Thread Jeevan Chalke
ted too? I am just visualizing what will be the scenario when both these features are checked-in. [1] https://www.postgresql.org/message-id/CA+TgmoZV8dw1H2bzZ9xkKwdrk8+XYa+DC9H=f7heo2zna5t...@mail.gmail.com > -- > Asif Rehman > Highgo Software (Canada/China/Pakistan) > URL : www.highgo

Re: WIP/PoC for parallel backup

2019-10-03 Thread Jeevan Chalke
ash the >> disk head back and forth between multiple files that are all being >> written at the same time, and approach (3) will therefore win by not >> thrashing the disk head. But, since spinning media are becoming less >> and less popular and are likely to have multiple dis

Re: WIP/PoC for parallel backup

2020-02-10 Thread Jeevan Chalke
; according to data received by threads. > > [1] > https://www.postgresql.org/message-id/flat/521B4B29.20009%402ndquadrant.com#189bf840c87de5908c0b4467d31b50af > > -- > Asif Rehman > Highgo Software (Canada/China/Pakistan) > URL : www.highgo.ca > > The latest changes look good to me. How

Re: WIP/PoC for parallel backup

2020-03-16 Thread Jeevan Chalke
ch WAL files from server */ +if (backupinfo->activeworkers == 0) +{ +backupinfo->backupstate = PB_BACKUP_COMPLETE; +} +break; Why free_filelist() is not called in PB_FETCH_WAL_FILES case? Thanks -- Jeevan Chalke Associate Database

Re: WIP/PoC for parallel backup

2020-04-07 Thread Jeevan Chalke
allel backup mode and have > generated a warning so that > user is aware of it and not expect it in the backup. > So, are you working on to make it work? I don't think a parallel backup feature should be creating a backup with no manifest. > > > > -- > -- > Asif Rehman >

Re: WIP/PoC for parallel backup

2020-04-06 Thread Jeevan Chalke
Asif, After recent backup manifest addition, patches needed to rebase and reconsideration of a few things like making sure that parallel backup creates a manifest file correctly or not etc. -- Jeevan Chalke Associate Database Architect & Team Lead, Product Development EnterpriseDB Corpora

Re: More new SQL/JSON item methods

2023-09-04 Thread Jeevan Chalke
e boolean from numeric > > than to serialize the numeric and parse an int? > Yeah, we can directly check the value = 0 for false, true otherwise. But looking at the PostgreSQL conversion to bool, it doesn't allow floating point values to be converted to boolean and only accepts int4. That's why I did the int4 conversion. Thanks -- Jeevan Chalke *Senior Staff SDE, Database Architect, and ManagerProduct Development* edbpostgres.com

Re: More new SQL/JSON item methods

2023-11-01 Thread Jeevan Chalke
Hello, On Tue, Oct 24, 2023 at 6:41 PM Andrew Dunstan wrote: > > On 2023-10-19 Th 02:06, Jeevan Chalke wrote: > > Thanks, Peter for the comments. > > On Fri, Oct 6, 2023 at 5:13 PM Peter Eisentraut > wrote: > >> On 29.08.23 09:05, Jeevan Chalke wrote: >>

Re: More new SQL/JSON item methods

2023-10-19 Thread Jeevan Chalke
Thanks, Peter for the comments. On Fri, Oct 6, 2023 at 5:13 PM Peter Eisentraut wrote: > On 29.08.23 09:05, Jeevan Chalke wrote: > > v1-0001-Implement-jsonpath-.bigint-.integer-and-.number-m.patch > > > > This commit implements jsonpath .bigint(), .integer(), and

Re: More new SQL/JSON item methods

2023-10-19 Thread Jeevan Chalke
On Wed, Oct 18, 2023 at 4:50 PM jian he wrote: > On Fri, Oct 6, 2023 at 7:47 PM Peter Eisentraut > wrote: > > > > On 29.08.23 09:05, Jeevan Chalke wrote: > > > v1-0001-Implement-jsonpath-.bigint-.integer-and-.number-m.patch > > > > > > This c

unrecognized node type while displaying a Path due to dangling pointer

2023-07-10 Thread Jeevan Chalke
Suggestions? Thanks -- Jeevan Chalke *Senior Staff SDE, Database Architect, and ManagerProduct Development* edbpostgres.com

Re: unrecognized node type while displaying a Path due to dangling pointer

2023-07-11 Thread Jeevan Chalke
On Tue, Jul 11, 2023 at 1:19 PM Alvaro Herrera wrote: > On 2023-Jul-11, Jeevan Chalke wrote: > > > 4. However, 2nd path was already sorted and passed as is to the > add_path(). > > 5. add_path() decides to reject this new path on some metrics. However, > in > > t

Re: unrecognized node type while displaying a Path due to dangling pointer

2023-07-11 Thread Jeevan Chalke
Hi Tom, On Tue, Jul 11, 2023 at 4:30 PM Tom Lane wrote: > Jeevan Chalke writes: > > Attached patch. > > I would be astonished if this fixes anything. The code still doesn't > know which paths are referenced by which other ones, and so the place > where we free a previo

Re: unrecognized node type while displaying a Path due to dangling pointer

2023-07-11 Thread Jeevan Chalke
On Tue, Jul 11, 2023 at 2:58 PM Jeevan Chalke < jeevan.cha...@enterprisedb.com> wrote: > > > On Tue, Jul 11, 2023 at 1:19 PM Alvaro Herrera > wrote: > >> On 2023-Jul-11, Jeevan Chalke wrote: >> >> > 4. However, 2nd path was already sorted and passed as

Re: recently added jsonpath method change jsonb_path_query, jsonb_path_query_first immutability

2024-02-07 Thread Jeevan Chalke
> [0] > https://git.postgresql.org/cgit/postgresql.git/commit/?id=66ea94e8e606529bb334515f388c62314956739e > > > ouch. Good catch. Clearly we need to filter these like we do for the > .datetime() method. > > > cheers > > > andrew > > -- > Andrew Dunstan > EDB: https://www.enterprisedb.com > > -- Jeevan Chalke *Principal, ManagerProduct Development* edbpostgres.com preserve-immutability.patch Description: Binary data

Re: recently added jsonpath method change jsonb_path_query, jsonb_path_query_first immutability

2024-02-08 Thread Jeevan Chalke
On Thu, Feb 8, 2024 at 2:22 PM jian he wrote: > On Thu, Feb 8, 2024 at 1:27 PM Jeevan Chalke > wrote: > > > > > > > > On Wed, Feb 7, 2024 at 9:13 PM jian he > wrote: > >> > >> On Wed, Feb 7, 2024 at 7:36 PM Jeevan Chalke > >> wrote

  1   2   >