Re: No index maximum? (was Re: [HACKERS] No merge sort?)

2003-03-23 Thread Taral
On Mon, Mar 17, 2003 at 11:23:47AM -0600, Taral wrote: Yes, that's exactly it. It's an index _scan_. It should simply be able to read the maximum straight from the btree. Still doesn't work, even with rewritten query. It sort a Limit(Sort(Index Scan)), with 1333 rows being pulled from the

Re: No index maximum? (was Re: [HACKERS] No merge sort?)

2003-03-17 Thread Taral
On Sat, Mar 15, 2003 at 09:23:28AM -0600, Bruno Wolff III wrote: On Fri, Mar 14, 2003 at 14:19:46 -0600, Taral [EMAIL PROTECTED] wrote: Same setup, different query: test= explain select max(time) from test where id = '1'; NOTICE: QUERY PLAN: Aggregate (cost=5084.67..5084.67

Re: No index maximum? (was Re: [HACKERS] No merge sort?)

2003-03-17 Thread Bruno Wolff III
On Mon, Mar 17, 2003 at 11:23:47 -0600, Taral [EMAIL PROTECTED] wrote: On Sat, Mar 15, 2003 at 09:23:28AM -0600, Bruno Wolff III wrote: On Fri, Mar 14, 2003 at 14:19:46 -0600, Taral [EMAIL PROTECTED] wrote: Same setup, different query: test= explain select max(time) from test

Re: No index maximum? (was Re: [HACKERS] No merge sort?)

2003-03-15 Thread Bruno Wolff III
On Fri, Mar 14, 2003 at 14:19:46 -0600, Taral [EMAIL PROTECTED] wrote: Same setup, different query: test= explain select max(time) from test where id = '1'; NOTICE: QUERY PLAN: Aggregate (cost=5084.67..5084.67 rows=1 width=0) - Index Scan using idx on test (cost=0.00..5081.33

No index maximum? (was Re: [HACKERS] No merge sort?)

2003-03-14 Thread Taral
Same setup, different query: test= explain select max(time) from test where id = '1'; NOTICE: QUERY PLAN: Aggregate (cost=5084.67..5084.67 rows=1 width=0) - Index Scan using idx on test (cost=0.00..5081.33 rows=1333 width=0) Since the index is (id, time), why isn't the index being used to