Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Liwandouw
Thanks a lot Andreas :) The tbltransaksi size = 263MB Total database size = 1277MB Quite small for so many records store in it. This group really helpfull. On Dec 1, 2013, at 8:29 PM, Andreas Kretschmer wrote: > Hengky Liwandouw wrote: > >> >> For Mat : what command i c

Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Liwandouw
n discount<=... ^ For Mat : what command i can use to show how big the tables in MB ? Thanks On Dec 1, 2013, at 8:06 PM, Torsten Förtsch wrote: > On 01/12/13 10:07, Hengky Liwandouw wrote: >> with qry1 as >> (select

Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Liwandouw
1)" "Sort Key: qry1.id, qry1.nama, qry1.kodebarang, qry1.namabarang" "Sort Method: external merge Disk: 71872kB" "-> CTE Scan on qry1 (cost=0.00..15330.38 rows=766519 width=376) (actual time=87.346

Re: [PERFORM] Speed up the query

2013-12-01 Thread Hengky Liwandouw
ry1.kodebarang, qry1.namabarang, qry1.bulan, qry1.keluar" " Sort Key: qry1.id, qry1.nama, qry1.kodebarang, qry1.namabarang" "-> CTE Scan on qry1 (cost=0.00..15329.82 rows=766491 width=376)" " Outpu

[PERFORM] Speed up the query

2013-11-30 Thread Hengky Liwandouw
Friends, i need help. I have query below that running well so far. it needs only 5.335 second to get data from 803.583 records. Here is the query : with qry1 as (select tanggal, extract(month from tanggal) as bulan, tblsupplier.id, nama, kodebarang, namabarang, keluar, case when disc