From: | Michael Lewis <mlewis(at)entrata(dot)com> |
---|---|
To: | Peter Grman <peter(dot)grman(at)gmail(dot)com> |
Cc: | PostgreSQL General <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Bad Estimate for multi tenant database queries |
Date: | 2019-09-03 18:39:34 |
Message-ID: | CAHOFxGoUNnvKAdnwjMmesLu+RkoMBtkDn+LiPrfewSYP40KCSw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
>
> CREATE STATISTICS MT_ReservationDepartureUtc (ndistinct) on "AccountCode",
> "DepartureUtc" from "Reservation"."Reservation";
> CREATE STATISTICS MT_ReservationArrivalUtc (ndistinct) on "AccountCode",
> "ArrivalUtc" from "Reservation"."Reservation";
> CREATE STATISTICS MT_ReservationNoShowFeeId (ndistinct) on "AccountCode",
> "NoShowFeeId" from "Reservation"."Reservation";
> CREATE STATISTICS MT_ReservationTimeSliceDefinitionId (ndistinct) on
> "AccountCode", "TimeSliceDefinitionId" from "Reservation"."Reservation";
>
> but that didn't help either
>
Did you try with 'dependencies' for the statistics_kind or only ndistinct?
What was default_statistics_target set to at the time you created the
extended statistics? I am not sure if that value is used, but I would
assume so.
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Lewis | 2019-09-03 19:00:39 | Re: literal vs dynamic partition constraint in plan execution |
Previous Message | Nagendra Bandi | 2019-09-03 16:01:23 | Re: Postgres HA issue - Standby server does not start after Master compute host is shut down |