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

Re: How to force Nested Loop plan?

From: Ron Johnson <ron(dot)l(dot)johnson(at)cox(dot)net>
To: PgSQL Performance ML <pgsql-performance(at)postgresql(dot)org>
Subject: Re: How to force Nested Loop plan?
Date: 2003-08-30 16:33:40
Message-ID: 1062261220.669.576.camel@haggis (view raw or flat)
Thread:
Lists: pgsql-performance
On Sat, 2003-08-30 at 10:47, Rob Nagler wrote:
> Tom Lane writes:
[snip]
> enough.  When I add this index, I will slow down inserts (about
> 20K/day) and increase data size (this is the second largest table in
[snip]

Since I gather that this is a web-site, can we presume that they
are clumped into an 8 hour range?  20,000/8 = 2,500/hour, which
is 41.67/minute.  If you can't do .69 inserts/second, something
is wrong, and it ain't hardware, and it ain't Postgresql...

> > PS: does server_id really need to be NUMERIC?  Why not integer, or at
> > worst bigint?
> 
> It is a NUMERIC(18).  It could be a bigint.  What would be the change
> in performance of this query if we changed it to bigint?

http://www.postgresql.org/docs/7.3/static/datatype.html#DATATYPE-INT
http://www.postgresql.org/docs/7.3/static/datatype.html#DATATYPE-NUMERIC-DECIMAL

Scalars are faster than arbitrary precision types.  Small (32 bit)
scalars are faster than bit (64 bit) scalars on x86 h/w.

-- 
-----------------------------------------------------------------
Ron Johnson, Jr. ron(dot)l(dot)johnson(at)cox(dot)net
Jefferson, LA USA

"Adventure is a sign of incompetence"
Stephanson, great polar explorer


In response to

pgsql-performance by date

Next:From: Bruce MomjianDate: 2003-08-30 16:47:53
Subject: Re: PostgreSQL HDD Grow capacity
Previous:From: Tom LaneDate: 2003-08-30 16:19:42
Subject: Re: How to force Nested Loop plan?

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