pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Marc Cousin <mcousin@sigma.fr>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-performance@postgresql.org
Subject: Re: Problem with large query
Date: Wed, 8 Sep 2004 16:49:59 +0200
Message-ID: <200409081650.00228.mcousin@sigma.fr> (raw)
In-Reply-To: <20149.1094654443@sss.pgh.pa.us>
References: <200409081549.49537.mcousin@sigma.fr>
	<20149.1094654443@sss.pgh.pa.us>

The query has been generated by business objects ... i'ill try to suggest to the developpers to remove this constant (if they can)...
The fields used by the sort are of type numeric(6,0) or (10,0) ...
Could it be better if the fields were integer or anything else ?


On Wednesday 08 September 2004 16:40, you wrote:
> Marc Cousin <mcousin@sigma.fr> writes:
> > I'm having trouble with a (quite big) query, and can't find a way to make it 
> > faster.
> 
> Seems like it might help if the thing could use a HashAggregate instead
> of sort/group.  Numeric is not hashable, so having those TO_NUMBER
> constants in GROUP BY destroys this option instantly ... but why in the
> world are you grouping by constants anyway?  You didn't say what the
> datatypes of the other columns were...
> 
>    regards, tom lane
> 



view thread (6+ messages)  latest in thread

Message-ID: <200409081650.00228.mcousin@sigma.fr>
Permalink:  ../200409081650.00228.mcousin@sigma.fr/
Also on:    postgresql.org/message-id/200409081650.00228.mcousin@sigma.fr

 · 

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: mcousin@sigma.fr, tgl@sss.pgh.pa.us
  Subject: Re: Problem with large query
  In-Reply-To: <200409081650.00228.mcousin@sigma.fr>

* 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