Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Lie
sorry, for now, work_mem=100MB On Mon, Dec 2, 2013 at 12:33 AM, Hengky Lie wrote: > Dear Torsten and friends, > > This is another good case to analyse why the query performance is not the > same : > > There are 2 query : > (1) > > with qry1 as ( > select subka

Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Lie
Dear Torsten and friends, This is another good case to analyse why the query performance is not the same : There are 2 query : (1) with qry1 as ( select subkategori, kodebarang as produkid, namabarang, keluar, tbltransaksi.modal*keluar as ttlmodal, case when tbltransaksi.discount<=100 t

Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Lie
Thanks Kevin. You are absolutely right. I should use parentheses, it is what i want for the query to do. It also increasing processing time to 5.444 seconds. Should be okay i think. On Sun, Dec 1, 2013 at 11:02 PM, Kevin Grittner wrote: > Hengky Liwandouw wrote: > > > where jualid is not null