1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-27 12:41:57 +03:00

Marginal tweaks to make sure that roundoff error won't cause us to make

a bad choice between sorted and hashed aggregation.
This commit is contained in:
Tom Lane
2003-02-15 21:39:58 +00:00
parent 056467ec6b
commit 0d7abfe7cf
2 changed files with 16 additions and 5 deletions

View File

@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.147 2003/02/15 20:12:40 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.148 2003/02/15 21:39:58 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@ -1003,7 +1003,7 @@ grouping_planner(Query *parse, double tuple_fraction)
tuple_fraction /= dNumGroups;
if (compare_fractional_path_costs(&hashed_p, &sorted_p,
tuple_fraction) <= 0)
tuple_fraction) < 0)
{
/* Hashed is cheaper, so use it */
use_hashed_grouping = true;