On Fri, Dec 18, 2020 at 6:03 PM Tom Lane wrote:
> Ken Tanzer writes:
> > Hi. I'm wondering if this is normal or at least known behavior?
> > Basically, if I'm specifying a LIMIT and also NULLS FIRST (or NULLS LAST
> > with a descending sort), I get a sequence
Hi. I'm wondering if this is normal or at least known behavior?
Basically, if I'm specifying a LIMIT and also NULLS FIRST (or NULLS LAST
with a descending sort), I get a sequence scan and a couple of orders of
magnitude slower query. Perhaps not relevantly, but definitely ironically,
the sort fi
On Fri, Aug 14, 2020 at 3:04 PM Justin Pryzby wrote:
> Due to the over-estimated rowcount, the planner believes that (more) rows
> will
> be output (sooner) than they actually are:
>
>-> Nested Loop Semi Join (cost=47.11..31367302.81 ROWS=611586
> width=336) (actual time=47.098..97236.123 R
Hi. I've got a query that runs fine (~50ms). When I add a "LIMIT 25" to
it though, it takes way longer. The query itself then takes about 4.5
seconds. And when I do an explain, it takes 90+ seconds for the same query!
Explains and detailed table/view info below. tbl_log has 1.2M records,
tbl_
On Sat, Jul 20, 2019 at 12:25 PM Tom Lane wrote:
> Ken Tanzer writes:
> > On Sat, Jul 20, 2019 at 7:46 AM Tom Lane wrote:
> >> and then to add insult to injury, has to search pg_description a second
> >> time for each hit.
>
> > Not sure if I'm underst
On Sat, Jul 20, 2019 at 7:46 AM Tom Lane wrote:
> But if you do so manually you'll end up with something like
>
> SELECT c.relname AS table, a.attname AS column, d.description AS comment
> FROM
> pg_catalog.pg_attribute a JOIN pg_catalog.pg_class c ON a.attrelid =
> c.oid
> LEFT JOIN pg_catal
Hi. I've got an app that queries pg_catalog to find any table columns that
have comments. After setting up PgBadger, it was #2 on my list of time
consuming queries, with min/max/avg duration of 199/2351/385 ms (across
~12,000 executions logged).
I'm wondering if there are any ways to speed this
On Wed, Jan 9, 2019 at 7:09 AM Mariel Cherkassky <
mariel.cherkas...@gmail.com> wrote:
> Hey Tom,
> I'm aware of how I can solve it. I wanted to understand why after
> installing the pg 9.6 packages suddenly psql tries to access the socket on
> /var/run/postgresql. Does the libpq default unix sock