summaryrefslogtreecommitdiff
path: root/sql/sql_select.h
diff options
context:
space:
mode:
authorIgor Babaev <igor@askmonty.org>2011-07-12 23:47:35 -0700
committerIgor Babaev <igor@askmonty.org>2011-07-12 23:47:35 -0700
commit5819dfcdf6144ff756495ba3e7cc066adb768dd4 (patch)
tree80f9eeb6bb863b54e2ae639258558ae290622a13 /sql/sql_select.h
parent419c20f10aaf6ef9fa7cb600084fdeaac2b0ae5a (diff)
downloadmariadb-git-5819dfcdf6144ff756495ba3e7cc066adb768dd4.tar.gz
Fixed LP bug #809206.
The bitmap of used tables must be evaluated for the select list of every materialized derived table / view and saved in a dedicated field. This is also applied to materialized subqueries.
Diffstat (limited to 'sql/sql_select.h')
-rw-r--r--sql/sql_select.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/sql_select.h b/sql/sql_select.h
index ae21db849ff..07872cffa3e 100644
--- a/sql/sql_select.h
+++ b/sql/sql_select.h
@@ -767,6 +767,8 @@ public:
make_join_statistics)
*/
table_map outer_join;
+ /* Bitmap of tables used in the select list items */
+ table_map select_list_used_tables;
ha_rows send_records,found_records,examined_rows,row_limit, select_limit;
/**
Used to fetch no more than given amount of rows per one
@@ -1134,6 +1136,7 @@ public:
return (table_map(1) << table_count) - 1;
}
void drop_unused_derived_keys();
+ inline void eval_select_list_used_tables();
/*
Return the table for which an index scan can be used to satisfy
the sort order needed by the ORDER BY/(implicit) GROUP BY clause