diff options
author | Varun Gupta <varunraiko1803@gmail.com> | 2017-07-17 15:06:42 +0530 |
---|---|---|
committer | Varun Gupta <varunraiko1803@gmail.com> | 2017-11-01 23:13:01 +0530 |
commit | 947ce922c950323a91a187b53d3315b6e6a582f0 (patch) | |
tree | 96f7acfbe030118bd2ed4fb51061a1809ac67557 /sql/item_windowfunc.cc | |
parent | 96565ac3118c936e81969cb68e3d1c6fa34c4114 (diff) | |
download | mariadb-git-947ce922c950323a91a187b53d3315b6e6a582f0.tar.gz |
Added the error ER_NOT_SINGLE_ELEMENT_ORDER_LIST for th percentile functions, these ensure that for the percentile
function we have the order list with exactly one element
Diffstat (limited to 'sql/item_windowfunc.cc')
-rw-r--r-- | sql/item_windowfunc.cc | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/sql/item_windowfunc.cc b/sql/item_windowfunc.cc index d5e13054755..c860c5ead68 100644 --- a/sql/item_windowfunc.cc +++ b/sql/item_windowfunc.cc @@ -111,18 +111,11 @@ Item_window_func::fix_fields(THD *thd, Item **ref) if (only_single_element_order_list()) { - //TODO (varun): need to change the error, the error should say that we have more than one element in the order list if (window_spec->order_list->elements != 1) { - my_error(ER_NO_ORDER_LIST_IN_WINDOW_SPEC, MYF(0), window_func()->func_name()); + my_error(ER_NOT_SINGLE_ELEMENT_ORDER_LIST, MYF(0), window_func()->func_name()); return true; } - /*switch(window_spec->order_list->firt->item[0]->type()) - { - case INT_TYPE: - default: - break; - }*/ } /* |