summaryrefslogtreecommitdiff
path: root/sql/sql_select.h
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-05-12 22:14:59 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2018-05-12 22:14:59 +0300
commit15419a558370aeed9521b498c34d50f20a8d47a5 (patch)
treecd15d32e9b61f297d8fafb048df85d9148951eb2 /sql/sql_select.h
parent5e84ea9634ac491f3da84f6c15987d4c1b1a5a3a (diff)
parent77867c147b8a278977203ad33d7daff0587a112a (diff)
downloadmariadb-git-15419a558370aeed9521b498c34d50f20a8d47a5.tar.gz
Merge 10.2 into 10.3
Diffstat (limited to 'sql/sql_select.h')
-rw-r--r--sql/sql_select.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/sql/sql_select.h b/sql/sql_select.h
index f8911fbba01..5e202e50152 100644
--- a/sql/sql_select.h
+++ b/sql/sql_select.h
@@ -1571,6 +1571,15 @@ public:
/* Number of tables actually joined at the top level */
uint exec_join_tab_cnt() { return tables_list ? top_join_tab_count : 0; }
+ /*
+ Number of tables in the join which also includes the temporary tables
+ created for GROUP BY, DISTINCT , WINDOW FUNCTION etc.
+ */
+ uint total_join_tab_cnt()
+ {
+ return exec_join_tab_cnt() + aggr_tables - 1;
+ }
+
int prepare(TABLE_LIST *tables, uint wind_num,
COND *conds, uint og_num, ORDER *order, bool skip_order_by,
ORDER *group, Item *having, ORDER *proc_param, SELECT_LEX *select,