summaryrefslogtreecommitdiff
path: root/sql/item_windowfunc.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/item_windowfunc.h')
-rw-r--r--sql/item_windowfunc.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/sql/item_windowfunc.h b/sql/item_windowfunc.h
index 4e0ba7fc43b..983f196a86c 100644
--- a/sql/item_windowfunc.h
+++ b/sql/item_windowfunc.h
@@ -448,6 +448,19 @@ public:
default:
return false;
}
+ }
+
+ bool is_order_list_mandatory()
+ {
+ switch (window_func->sum_func()) {
+ case Item_sum::RANK_FUNC:
+ case Item_sum::DENSE_RANK_FUNC:
+ case Item_sum::PERCENT_RANK_FUNC:
+ case Item_sum::CUME_DIST_FUNC:
+ return true;
+ default:
+ return false;
+ }
}
/*