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

Re: Simple query, 10 million records...MySQL ten times faster

From: Jeff Hoffmann <jeff(at)propertykey(dot)com>
To: zardozrocks <zardozrocks(at)gmail(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: Simple query, 10 million records...MySQL ten times faster
Date: 2007-04-26 21:40:17
Message-ID: 46311C41.4000906@propertykey.com (view raw or flat)
Thread:
Lists: pgsql-performance
zardozrocks wrote:
> I have this table:
> 
> CREATE TABLE test_zip_assoc (
>     id serial NOT NULL,
>     f_id integer DEFAULT 0 NOT NULL,
>     lat_radians numeric(6,5) DEFAULT 0.00000 NOT NULL,
>     long_radians numeric(6,5) DEFAULT 0.00000 NOT NULL
> );
> CREATE INDEX lat_radians ON test_zip_assoc USING btree (lat_radians);
> CREATE INDEX long_radians ON test_zip_assoc USING btree
> (long_radians);

Maybe I'm missing something, but wouldn't it be easier to just use 
PostGIS?  Or failing that, using the vanilla built-in point type and an 
r-tree index?  That's what r-tree indexes are made for.

-- 
Jeff Hoffmann
Head Plate Spinner
PropertyKey.com

In response to

pgsql-performance by date

Next:From: Alexander StauboDate: 2007-04-26 22:34:36
Subject: Re: index structure for 114-dimension vector
Previous:From: Luke LonerganDate: 2007-04-26 21:39:56
Subject: Re: Simple query, 10 million records...MySQL ten times faster

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