pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Sidar López Cruz <sidarlopez@hotmail.com>
To: pgsql-performance@postgresql.org
Subject: performance on query
Date: Wed, 26 Oct 2005 17:47:31 -0600
Message-ID: <BAY23-F36614886359D96AC48B8BCE690@phx.gbl> (raw)

I DON'T KNOW WHAT TO DO WITH THIS QUERYS...
Comparation with sql server, sql server wins !!!


Table sizes:
archivos: 40MB
fotos: 55MB

select count(1) from fotos f where not exists (select a.archivo from 
archivos a where a.archivo=f.archivo)
173713 ms.
110217 ms.
83122 ms.

select count(*) from
(
	select archivo from fotos
	    except
	select archivo from archivos
) x;
201479 ms.

SELECT count(*)
FROM fotos f
LEFT JOIN archivos a USING(archivo)
WHERE a.archivo IS NULL
199523 ms.

_________________________________________________________________
MSN Amor: busca tu ½ naranja http://latam.msn.com/amor/




view thread (2+ messages)  latest in thread

Message-ID: <BAY23-F36614886359D96AC48B8BCE690@phx.gbl>
Permalink:  ../BAY23-F36614886359D96AC48B8BCE690@phx.gbl/
Also on:    postgresql.org/message-id/BAY23-F36614886359D96AC48B8BCE690@phx.gbl

 · 

reply

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: sidarlopez@hotmail.com
  Subject: Re: performance on query
  In-Reply-To: <BAY23-F36614886359D96AC48B8BCE690@phx.gbl>

* 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