Re: Performance pb vs SQLServer.
От | Stéphane COEZ |
---|---|
Тема | Re: Performance pb vs SQLServer. |
Дата | |
Msg-id | 20050815090515.0D75E100008F@mwinf0703.wanadoo.fr обсуждение исходный текст |
Ответ на | Re: Performance pb vs SQLServer. (John Arbash Meinel <john@arbash-meinel.com>) |
Список | pgsql-performance |
John Arbash Meinel wrote : > > You might also try a different query, something like: > > SELECT DISTINCT cod FROM mytable ORDER BY cod GROUP BY cod; > (You may or may not want order by, or group by, try the different > combinations.) > It might be possible to have the planner realize that all you > want is unique rows, just doing a group by doesn't give you that. > > John > =:-> > Thanks John, but using SELECT DISTINCT with or without Order nor Group by is worth... 30 sec (with index) - stopped at 200 sec without index... So Hash Aggregate is much better than index scan ... > > > >Thanks for help. > > > >Stéphane COEZ > > > > > > > > > >---------------------------(end of > >broadcast)--------------------------- > >TIP 9: In versions below 8.0, the planner will ignore your desire to > > choose an index scan if your joining column's datatypes do not > > match > > > > > > > > >
В списке pgsql-performance по дате отправления: