mirror of
https://github.com/postgres/postgres.git
synced 2025-08-31 17:02:12 +03:00
genericcostestimate() neglected to include qual startup cost in
indexTotalCost. I think this may not make any real difference in 7.4, but it definitely is a problem with CVS tip's new equation.
This commit is contained in:
@@ -15,7 +15,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.147.2.2 2004/02/02 03:07:14 tgl Exp $
|
* $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.147.2.3 2004/02/27 21:44:44 tgl Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@@ -3977,7 +3977,7 @@ genericcostestimate(Query *root, RelOptInfo *rel,
|
|||||||
*/
|
*/
|
||||||
cost_qual_eval(&index_qual_cost, indexQuals);
|
cost_qual_eval(&index_qual_cost, indexQuals);
|
||||||
*indexStartupCost = index_qual_cost.startup;
|
*indexStartupCost = index_qual_cost.startup;
|
||||||
*indexTotalCost = numIndexPages +
|
*indexTotalCost = numIndexPages + index_qual_cost.startup +
|
||||||
(cpu_index_tuple_cost + index_qual_cost.per_tuple) * numIndexTuples;
|
(cpu_index_tuple_cost + index_qual_cost.per_tuple) * numIndexTuples;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Reference in New Issue
Block a user