From: | Shaun Thomas <sthomas(at)peak6(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | David Greco <David_Greco(at)harte-hanks(dot)com>, "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org> |
Subject: | Re: Real vs Int performance |
Date: | 2011-01-27 14:30:15 |
Message-ID: | 4D418177.1040401@peak6.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
On 01/27/2011 08:18 AM, Tom Lane wrote:
> Not if you can persuade the client-side code to output integers as
> integers. "numeric" type is orders of magnitude slower than integers.
I sadly have to vouch for this. My company converted an old Oracle app
and they changed all their primary keys (and foreign keys, and random
larger int fields) to NUMERIC(19)'s. I've convinced them all new stuff
should be BIGINT if they need that level of coverage, but the damage is
already done.
I'm not sure about orders of magnitude on the storage/index side, but my
tests gave us a 10% boost if just the keys are switched over to INT or
BIGINT.
--
Shaun Thomas
OptionsHouse | 141 W. Jackson Blvd. | Suite 800 | Chicago IL, 60604
312-676-8870
sthomas(at)peak6(dot)com
______________________________________________
See http://www.peak6.com/email_disclaimer.php
for terms and conditions related to this email
From | Date | Subject | |
---|---|---|---|
Next Message | Kevin Grittner | 2011-01-27 14:51:08 | Re: Why I lost the last pg_xlog file? |
Previous Message | Tom Lane | 2011-01-27 14:18:11 | Re: Real vs Int performance |