Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
5.5(EOL)
-
None
-
5.5.51 & 10.2.2
Description
The problem is reproducible for me only on 5.5. It's possible that it was fixed in 10.x by the patch for MDEV-5781. If so, and if it is not too dangerous, please feel free to close it as 'Won't fix' (in 5.5).
CREATE TABLE t1 (i INT); |
INSERT INTO t1 VALUES (1),(2); |
SELECT STDDEV_SAMP(ROUND('0', 309)) FROM t1; |
Stack trace from 5.5 commit 5fdb3cfcd432b85dc305a1a61c2d018a798a6ac3 |
mysqld: /data/src/5.5/sql/item_sum.cc:1765: virtual double Item_sum_std::val_real(): Assertion `nr >= 0.0' failed.
|
160801 0:42:38 [ERROR] mysqld got signal 6 ;
|
 |
#6 0x00007f558ee0c266 in __assert_fail_base (fmt=0x7f558ef45238 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0xdbee62 "nr >= 0.0", file=file@entry=0xdbecbb "/data/src/5.5/sql/item_sum.cc", line=line@entry=1765, function=function@entry=0xdbf800 <Item_sum_std::val_real()::__PRETTY_FUNCTION__> "virtual double Item_sum_std::val_real()") at assert.c:92
|
#7 0x00007f558ee0c312 in __GI___assert_fail (assertion=0xdbee62 "nr >= 0.0", file=0xdbecbb "/data/src/5.5/sql/item_sum.cc", line=1765, function=0xdbf800 <Item_sum_std::val_real()::__PRETTY_FUNCTION__> "virtual double Item_sum_std::val_real()") at assert.c:101
|
#8 0x00000000008596b4 in Item_sum_std::val_real (this=0x7f55899483c0) at /data/src/5.5/sql/item_sum.cc:1765
|
#9 0x00000000007cfafa in Item::send (this=0x7f55899483c0, protocol=0x7f558aa74628, buffer=0x7f5590e631b0) at /data/src/5.5/sql/item.cc:6595
|
#10 0x0000000000568e30 in Protocol::send_result_set_row (this=0x7f558aa74628, row_items=0x7f5589949040) at /data/src/5.5/sql/protocol.cc:903
|
#11 0x00000000005cb47a in select_send::send_data (this=0x7f5589948c50, items=...) at /data/src/5.5/sql/sql_class.cc:2374
|
#12 0x000000000065e459 in end_send_group (join=0x7f5589948c70, join_tab=0x7f5589949f28, end_of_records=true) at /data/src/5.5/sql/sql_select.cc:18186
|
#13 0x000000000065b251 in sub_select (join=0x7f5589948c70, join_tab=0x7f5589949c08, end_of_records=true) at /data/src/5.5/sql/sql_select.cc:16904
|
#14 0x000000000065ad3a in do_select (join=0x7f5589948c70, fields=0x7f5589949040, table=0x0, procedure=0x0) at /data/src/5.5/sql/sql_select.cc:16615
|
#15 0x000000000063955f in JOIN::exec (this=0x7f5589948c70) at /data/src/5.5/sql/sql_select.cc:2873
|
#16 0x0000000000639d2a in mysql_select (thd=0x7f558aa74060, rref_pointer_array=0x7f558aa77ce0, tables=0x7f55899485c8, wild_num=0, fields=..., conds=0x0, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=2147748608, result=0x7f5589948c50, unit=0x7f558aa77390, select_lex=0x7f558aa77a70) at /data/src/5.5/sql/sql_select.cc:3094
|
#17 0x0000000000630610 in handle_select (thd=0x7f558aa74060, lex=0x7f558aa772e0, result=0x7f5589948c50, setup_tables_done_option=0) at /data/src/5.5/sql/sql_select.cc:319
|
#18 0x0000000000609b07 in execute_sqlcom_select (thd=0x7f558aa74060, all_tables=0x7f55899485c8) at /data/src/5.5/sql/sql_parse.cc:4689
|
#19 0x0000000000602e58 in mysql_execute_command (thd=0x7f558aa74060) at /data/src/5.5/sql/sql_parse.cc:2234
|
#20 0x000000000060c6d2 in mysql_parse (thd=0x7f558aa74060, rawbuf=0x7f5589948078 "SELECT STDDEV_SAMP(ROUND('0', 309)) FROM t1", length=43, parser_state=0x7f5590e64650) at /data/src/5.5/sql/sql_parse.cc:5934
|
#21 0x00000000006003e7 in dispatch_command (command=COM_QUERY, thd=0x7f558aa74060, packet=0x7f558b74e061 "", packet_length=43) at /data/src/5.5/sql/sql_parse.cc:1079
|
#22 0x00000000005ff5a1 in do_command (thd=0x7f558aa74060) at /data/src/5.5/sql/sql_parse.cc:793
|
#23 0x000000000070171f in do_handle_one_connection (thd_arg=0x7f558aa74060) at /data/src/5.5/sql/sql_connect.cc:1270
|
#24 0x00000000007014ac in handle_one_connection (arg=0x7f558aa74060) at /data/src/5.5/sql/sql_connect.cc:1186
|
#25 0x00000000009437a5 in pfs_spawn_thread (arg=0x7f558b77a300) at /data/src/5.5/storage/perfschema/pfs.cc:1015
|
#26 0x00007f5590aa00a4 in start_thread (arg=0x7f5590e65700) at pthread_create.c:309
|
#27 0x00007f558eec687d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111
|
Attachments
Issue Links
- relates to
-
MDEV-10468 [all versions] Assertion `nr >= 0.0' failed in Item_sum_std::val_real()
- Closed
-
MDEV-5781 Item_sum_std::val_real(): Assertion `nr >= 0.0' fails on query with STDDEV_POP, ROUND and variable
- Closed