diff options
author | Alexander Nozdrin <alik@sun.com> | 2009-10-19 17:17:08 +0400 |
---|---|---|
committer | Alexander Nozdrin <alik@sun.com> | 2009-10-19 17:17:08 +0400 |
commit | 3251065aef83d6cc8088b03e56f6f3242786de66 (patch) | |
tree | 18863557a9b43b168f930debb4fdcc69a37f4e82 /sql/sql_class.h | |
parent | 9b4b453ab8a5f7c7fa06b4ef22b6a10867fac187 (diff) | |
parent | bf14598c9903067474a7cdf1c49bca9f52d0c55a (diff) | |
download | mariadb-git-3251065aef83d6cc8088b03e56f6f3242786de66.tar.gz |
Merge from mysql-5.1.
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index 3dc6a49e964..bb5c700e4dc 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -2647,7 +2647,32 @@ public: MI_COLUMNDEF *recinfo,*start_recinfo; KEY *keyinfo; ha_rows end_write_records; - uint field_count,sum_func_count,func_count; + /** + Number of normal fields in the query, including those referred to + from aggregate functions. Hence, "SELECT `field1`, + SUM(`field2`) from t1" sets this counter to 2. + + @see count_field_types + */ + uint field_count; + /** + Number of fields in the query that have functions. Includes both + aggregate functions (e.g., SUM) and non-aggregates (e.g., RAND). + Also counts functions referred to from aggregate functions, i.e., + "SELECT SUM(RAND())" sets this counter to 2. + + @see count_field_types + */ + uint func_count; + /** + Number of fields in the query that have aggregate functions. Note + that the optimizer may choose to optimize away these fields by + replacing them with constants, in which case sum_func_count will + need to be updated. + + @see opt_sum_query, count_field_types + */ + uint sum_func_count; uint hidden_field_count; uint group_parts,group_length,group_null_parts; uint quick_group; |