From: | "Hiroshi Inoue" <Inoue(at)tpf(dot)co(dot)jp> |
---|---|
To: | "pgsql-hackers" <pgsql-hackers(at)postgreSQL(dot)org> |
Subject: | Optimization FAQ ? |
Date: | 1999-07-02 00:14:10 |
Message-ID: | 000401bec41f$ce81dcc0$2801007e@cadzone.tpf.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hello all,
I got the following result.
It's FAQ ?
drop table int2t;
create table int2t (id int2 primary key);
explain select * from int2t where id=1;
NOTICE: QUERY PLAN:
Seq Scan on int2t (cost=43.00 rows=2 width=2)
explain select * from int2t where id=1::int2;
NOTICE: QUERY PLAN:
Index Scan using int2t_pkey on int2t (cost=2.05 rows=2 width=2)
explain select * from int2t where id='1';
NOTICE: QUERY PLAN:
Index Scan using int2t_pkey on int2t (cost=2.05 rows=2 width=2)
Right behavior ?
Regards.
Hiroshi Inoue
Inoue(at)tpf(dot)co(dot)jp
From | Date | Subject | |
---|---|---|---|
Next Message | Dmitry Samersoff | 1999-07-02 08:27:33 | MySQL comparison ... |
Previous Message | Collin F. Lynch | 1999-07-01 20:48:53 | Time and microseconds? |