From: Tom Lane <tgl@sss.pgh.pa.us>
To: Carlos Benkendorf <carlosbenkendorf@yahoo.com.br>
Cc: pgsql-performance@postgresql.org
Subject: Re: ORDER BY costs
Date: Wed, 21 Dec 2005 14:39:35 -0500
Message-ID: <15455.1135193975@sss.pgh.pa.us> (raw)
In-Reply-To: <20051221181601.45239.qmail@web35508.mail.mud.yahoo.com>
References: <20051221181601.45239.qmail@web35508.mail.mud.yahoo.com>
Carlos Benkendorf <carlosbenkendorf@yahoo.com.br> writes:
> Table "iparq.arript"
> Column | Type | Modifiers
> -------------------+-----------------------+-----------
> anocalc | numeric(4,0) | not null
> cadastro | numeric(8,0) | not null
> codvencto | numeric(2,0) | not null
> parcela | numeric(2,0) | not null
> inscimob | character varying(18) | not null
> codvencto2 | numeric(2,0) | not null
> parcela2 | numeric(2,0) | not null
> codpropr | numeric(10,0) | not null
> dtaven | numeric(8,0) | not null
> anocalc2 | numeric(4,0) |
I suspect you'd find a significant performance improvement from changing
the NUMERIC columns to int or bigint as needed. Numeric comparisons are
pretty slow.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tgl@sss.pgh.pa.us, carlosbenkendorf@yahoo.com.br
Subject: Re: ORDER BY costs
In-Reply-To: <15455.1135193975@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox