Skip site navigation (1) Skip section navigation (2)

Re: PG planning randomly ?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Laurent Raufaste" <analogue(at)glop(dot)org>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: PG planning randomly ?
Date: 2008-02-26 16:31:42
Message-ID: 3637.1204043502@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-performance
"Laurent Raufaste" <analogue(at)glop(dot)org> writes:
> I'm having some issues with this simple query:

> SELECT
>   _comment.*,
>   _article.title AS article_title,
>   _article.reference AS article_reference
> FROM
>   _comment
>   INNER JOIN _article
>     ON _article.id = _comment.parent_id
> WHERE
>   _comment.path <@ '0.1.3557034'
> ORDER BY
>   _comment.date_publishing DESC
> OFFSET 0
> LIMIT 5
> ;

> The varying information here is the ltree path "0.1.3557034"

What PG version is this?

If it's 8.2 or later then increasing the stats target for _comment.path
to 100 or more would likely help.

			regards, tom lane

In response to

Responses

pgsql-performance by date

Next:From: Kynn JonesDate: 2008-02-26 16:49:21
Subject: Re: Q on views and performance
Previous:From: Joel StevensonDate: 2008-02-26 16:26:30
Subject: Re: LISTEN / NOTIFY performance in 8.3

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group