On Fri, 2003-11-07 at 19:11, Mark Harrison wrote: > I have indexed two columns in a table. Can somebody explain to me why > the first query below uses an Index Scan while the second uses a Seq > Scan?
The first expects to find a single row, the second expects to find 17000 rows, a significant portion of the table where an index scan would be a loss based on current tuning parameters. -- Rod Taylor <pg [at] rbt [dot] ca> Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL ---------------------------(end of broadcast)--------------------------- TIP 8: explain analyze is your friend