Re: How to read query plan - Mailing list pgsql-performance

From Tom Lane
Subject Re: How to read query plan
Date
Msg-id 14079.1110817416@sss.pgh.pa.us
Whole thread Raw
In response to Re: How to read query plan  (Miroslav Šulc <miroslav.sulc@startnet.cz>)
Responses Re: How to read query plan
List pgsql-performance
=?ISO-8859-15?Q?Miroslav_=A6ulc?= <miroslav.sulc@startnet.cz> writes:
> PFC wrote:
>> Instead of a varchar(1) containing 'y' or 'n' you could use a BOOL
>> or an  integer.

> Sure I could. The problem is our project still supports both MySQL and
> PostgreSQL. We used enum('Y','N') in MySQL so there would be a lot of
> changes in the code if we would change to the BOOL data type.

Just FYI, I did a quick search-and-replace on your dump to replace
varchar(1) by "char", which makes the column fixed-width without any
change in the visible data.  This made hardly any difference in the
join speed though :-(.  So that is looking like a dead end.

John's idea about re-joining to the main table to pick up the bulk of
its fields only after joining to the sub-tables might work.

            regards, tom lane

pgsql-performance by date:

Previous
From: Greg Stark
Date:
Subject: Re: How to read query plan
Next
From: Miroslav Šulc
Date:
Subject: Re: How to read query plan