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

Re: problems doing sub-selects on PostgreSQL 7.1.3 and Solaris 7

From: "Heather Johnson" <hjohnson(at)nypost(dot)com>
To: "bpalmer" <bpalmer(at)crimelabs(dot)net>
Cc: <pgsql-admin(at)postgresql(dot)org>, "Harry Ford" <hford(at)globix(dot)com>, "Serge Canizares" <serge(at)enluminaire(dot)com>, "Marie Musacchio" <marie(at)nypost(dot)com>
Subject: Re: problems doing sub-selects on PostgreSQL 7.1.3 and Solaris 7
Date: 2001-12-11 14:47:41
Message-ID: 01e401c18252$c9449a10$510b10ac@sephie (view raw or flat)
Thread:
Lists: pgsql-adminpgsql-general
Thanks Brandon---that's a very good idea. I'd still like to know why my x86
box can handle the less effecient query better than an E-450, but this is
what I'll do until I can get my curiosity satisfied. ;)

Heather

----- Original Message -----
From: "bpalmer" <bpalmer(at)crimelabs(dot)net>
To: "Heather Johnson" <hjohnson(at)nypost(dot)com>
Cc: <pgsql-admin(at)postgresql(dot)org>
Sent: Monday, December 10, 2001 5:34 PM
Subject: Re: [ADMIN] problems doing sub-selects on PostgreSQL 7.1.3 and
Solaris 7


> >     SELECT count(*) FROM users WHERE id NOT IN ( SELECT users_id FROM
users_demographics );
>
> I'm not sure about the difference in speed,  but try the following for a
> much faster query:
>
> SELECT count(id)
> FROM users
>
> EXCEPT
>
> SELECT users_id
> FROM  users_demographics
>
> Should be a great deal faster.
>
> - Brandon
>
>
>
> --------------------------------------------------------------------------
--
>  c: 646-456-5455                                            h:
201-798-4983
>  b. palmer,  bpalmer(at)crimelabs(dot)net
pgp:crimelabs.net/bpalmer.pgp5
>


In response to

pgsql-admin by date

Next:From: Heather JohnsonDate: 2001-12-11 14:49:32
Subject: Re: problems doing sub-selects on PostgreSQL 7.1.3 and Solaris 7
Previous:From: Heather JohnsonDate: 2001-12-11 14:45:45
Subject: Re: problems doing sub-selects on PostgreSQL 7.1.3 and Solaris 7

pgsql-general by date

Next:From: Holger KrugDate: 2001-12-11 14:51:50
Subject: Re: bug or my ignorance ?
Previous:From: Heather JohnsonDate: 2001-12-11 14:45:45
Subject: Re: problems doing sub-selects on PostgreSQL 7.1.3 and Solaris 7

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