Search Postgresql Archives

Re: The planner chooses seqscan+sort when there is an index on the sort column

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Csaba Nagy wrote:

select * from table order by col_1;

Isn't it supposed to choose the index scan at least when
enable_seqscan=off ? Even if it is indeed not faster to do the index
scan than seqscan+sort.

I think because you've asked for every row, it's going to have to scan the whole table anyway, to determine MVCC "liveness" of the rows (sorry, dunno what the correct word is).

- John Burger
  MITRE



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux