Re: Query performance issue - Mailing list pgsql-performance

From Michael Lewis
Subject Re: Query performance issue
Date
Msg-id CAHOFxGo-YY-0RMzEx=JzNiu_M6fqpd1TskWDLGZ8xvfFEu813A@mail.gmail.com
Whole thread Raw
In response to Re: Query performance issue  (Nagaraj Raj <nagaraj.sf@yahoo.com>)
Responses Re: Query performance issue
Re: Query performance issue
List pgsql-performance
CREATE INDEX receiving_item_delivered_received ON receiving_item_delivered_received USING btree ( eventtype, replenishmenttype, serial_no, eventtime DESC );

More work_mem as Tomas suggests, but also, the above index should find the candidate rows by the first two keys, and then be able to skip the sort by reading just that portion of the index that matches

eventtype='LineItemdetailsReceived'
and replenishmenttype = 'DC2SWARRANTY'

pgsql-performance by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Query performance issue
Next
From: Michael Lewis
Date:
Subject: Re: Query performance issue