summaryrefslogtreecommitdiff
path: root/mysql-test/t/func_gconcat.test
Commit message (Collapse)AuthorAgeFilesLines
* Create 'main' test directory and move 't' and 'r' thereMichael Widenius2018-03-291-990/+0
|
* MDEV-11297: Add support for LIMIT clause in GROUP_CONCAT()Varun Gupta2017-12-081-0/+73
|
* MDEV-12803 Improve function parameter data type controlAlexander Barkov2017-05-291-1/+1
|
* MDEV-7635: Update tests to adapt to the new default sql_modeNirbhay Choubey2017-02-101-2/+2
|
* MDEV-7635: Part 1Nirbhay Choubey2017-02-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | innodb_autoinc_lock_mode = 2 innodb_buffer_pool_dump_at_shutdown = ON innodb_buffer_pool_dump_pct = 25 innodb_buffer_pool_load_at_startup = ON innodb_checksum_algorithm = CRC32 innodb_file_format = Barracuda innodb_large_prefix = ON innodb_log_compressed_pages = ON innodb_purge_threads = 4 innodb_strict_mode = ON binlog_annotate_row_events = ON binlog_format = MIXED binlog-row-event-max-size = 8192 group_concat_max_len = 1M lock_wait_timeout = 86400 log_slow_admin_statements = ON log_slow_slave_statements = ON log_warnings = 2 max_allowed_packet = 16M replicate_annotate_row_events = ON slave_net_timeout = 60 sync_binlog = 1 aria_recover = BACKUP,QUICK myisam_recover_options = BACKUP,QUICK
* MDEV-10124 Incorrect usage of CUBE/ROLLUP and ORDER BY with GROUP_CONCAT(a ↵Alexander Barkov2016-06-011-0/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ORDER BY a) Allowing GROUP_CONCAT(... ORDER BY ..) in queries with ROLLUP. The story of the related code: 1. The original patch from Wax commit: 0b505fb437eedd1b31c99888247c2259539c095b date: Tue Mar 18 03:07:40 2003 opt_gorder_clause reused the regular order_clause, which already had some protection against ROLLUP queries: order_clause: ORDER_SYM BY { LEX *lex=Lex; if (lex->current_select->linkage != GLOBAL_OPTIONS_TYPE && lex->current_select->select_lex()->olap != UNSPECIFIED_OLAP_TYPE) { net_printf(lex->thd, ER_WRONG_USAGE, "CUBE/ROLLUP", "ORDER BY"); YYABORT; } } order_list; The assumption that ORDER BY in group_concat() had to have the same ROLLUP restriction (with order_clause) was wrong. Moreover, GROUP_CONCAT() in select_item_list was not affected by this restriction, because WITH ROLLUP goes after select_item_list and therefore sel->olap is always equal to UNSPECIFIED_OLAP_TYPE during select_item_list. GROUP BY was not affected for two reasons: - it goes before WITH ROLLUP and sel->olap is still UNSPECIFIED_OLAP_TYPE - Aggregate functions like AVG(), GROUP_CONCAT() in GROUP BY are not allowed So only GROUP_CONCAT() in HAVING and ORDER BY clauses were erroneously affected by this restriction. 2. Bug#27848 rollup in union part causes error with order of union commit: 3f6073ae63f9cb738cb6f0a6a8136e1d21ba0e1b Author: unknown <igor@olga.mysql.com> 2007-12-15 01:42:46 The condition in the ROLLUP protection code became more complex. Note, opt_gconcat_order still reused the regular order_clause. 3. Bug#16347426 ASSERTION FAILED: (SELECT_INSERT && !TABLES->NEXT_NAME_RESOLUTION_TABLE) || !TAB commit: 2d83663380f5c0ea720e31f51898912b0006cd9f author: Chaithra Gopalareddy <chaithra.gopalareddy@oracle.com> date: 2013-04-14 06:00:49 opt_gorder_clause was refactored not to use order_clause and to collect information directly to select->gorder_list. The ROLLUP protection code was duplicated from order_clause to the new version of opt_gorder_clause.
* MDEV-5542: GROUP_CONCAT truncate output to 65.536 chars when using DISTINCT ↵Oleksandr Byelkin2016-03-011-0/+41
| | | | | | or ORDER BY port of mysql fix WL#6098
* MDEV-7821 - Server crashes in Item_func_group_concat::fix_fields on 2ndSergey Vojtovich2015-07-311-0/+11
| | | | | | | | | | | execution of PS GROUP_CONCAT() with ORDER BY column position may crash server on PS reexecution. The problem was that arguments array of GROUP_CONCAT() was adjusted to point to temporary elements (resolved ORDER BY fields) during first execution. This patch expands rev. 08763096cb to restore original arguments array as well.
* CRLF->LFSergei Golubchik2015-06-021-3/+3
|
* MDEV-7820 Server crashes in in my_strcasecmp_utf8 on subquery in ORDER BY ↵5.5-MDEV-7820Vicențiu Ciorbaru2015-04-151-0/+18
| | | | | | | | | clause of GROUP_CONCAT It is possible for Item_field to have a NULL field_name. This is true if the Item_field is created based on a field in a temporary table that has no name. It is thus necessary to do a null check before attempting a strcmp.
* MDEV-3987 uninitialized read in Item_cond::fix_fields leads to crash: select ↵Sergei Golubchik2013-01-081-0/+8
| | | | | | .. where .. in ( select ... ) change Item_func_group_concat to use max_length according to the expected semantics
* non-functional cleanup, clarifying CONVERT_IF_BIGGER_TO_BLOBSergei Golubchik2013-01-071-1/+1
|
* 5.1-bugteam->5.5-bugteam mergeSergey Glukhov2010-12-131-0/+11
|\
| * Bug#58396 group_concat and explain extended are still crashySergey Glukhov2010-12-131-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Explain fails at fix_fields stage and some items are left unfixed, particulary Item_group_concat. Item_group_concat::orig_args field is uninitialized in this case and Item_group_concat::print call leads to crash. The fix: move the initialization of Item_group_concat::orig_args into constructor. mysql-test/r/func_gconcat.result: test case mysql-test/t/func_gconcat.test: test case sql/item_sum.cc: move the initialization of Item_group_concat::orig_args into constructor.
* | mergeGeorgi Kodinov2010-11-261-0/+11
|\ \ | |/
| * test case fixSergey Glukhov2010-11-011-0/+2
| |
| * Bug#57194 group_concat cause crash and/or invalid memory reads with type errorsSergey Glukhov2010-10-291-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The problem is caused by bug49487 fix and became visible after after bug56679 fix. Items are cleaned up and set to unfixed state after filling derived table. So we can not rely on item::fixed state in Item_func_group_concat::print and we can not use 'args' array as items there may be cleaned up. The fix is always to use orig_args array of items as it always should contain the correct data. mysql-test/r/func_gconcat.result: test case mysql-test/t/func_gconcat.test: test case sql/item_sum.cc: The fix is always to use orig_args array of items.
* | mergeGeorgi Kodinov2010-08-201-0/+5
|\ \
| * \ mergeGeorgi Kodinov2010-08-201-0/+21
| |\ \ | | |/
* | | addendum to the fix for bug #54476: fixed a failing test case.Georgi Kodinov2010-08-031-0/+3
| | |
* | | Manual merge from 5.1Alexey Kopytov2010-07-281-1/+13
|\ \ \ | |/ / |/| / | |/
| * Bug #54476: crash when group_concat and 'with rollup' inAlexey Kopytov2010-07-231-1/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | prepared statements Using GROUP_CONCAT() together with the WITH ROLLUP modifier could crash the server. The reason was a combination of several facts: 1. The Item_func_group_concat class stores pointers to ORDER objects representing the columns in the ORDER BY clause of GROUP_CONCAT(). 2. find_order_in_list() called from Item_func_group_concat::setup() modifies the ORDER objects so that their 'item' member points to the arguments list allocated in the Item_func_group_concat constructor. 3. In some cases (e.g. in JOIN::rollup_make_fields) a copy of the original Item_func_group_concat object could be created by using the Item_func_group_concat::Item_func_group_concat(THD *thd, Item_func_group_concat *item) copy constructor. The latter essentially creates a shallow copy of the source object. Memory for the arguments array is allocated on thd->mem_root, but the pointers for arguments and ORDER are copied verbatim. What happens in the test case is that when executing the query for the first time, after a copy of the original Item_func_group_concat object has been created by JOIN::rollup_make_fields(), find_order_in_list() is called for this new object. It then resolves ORDER BY by modifying the ORDER objects so that they point to elements of the arguments array which is local to the cloned object. When thd->mem_root is freed upon completing the execution, pointers in the ORDER objects become invalid. Those ORDER objects, however, are also shared with the original Item_func_group_concat object which is preserved between executions of a prepared statement. So the first call to find_order_in_list() for the original object on the second execution tries to dereference an invalid pointer. The solution is to create copies of the ORDER objects when copying Item_func_group_concat to not leave any stale pointers in other instances with different lifecycles. mysql-test/r/func_gconcat.result: Test case for bug #54476. mysql-test/t/func_gconcat.test: Test case for bug #54476. sql/item_sum.cc: Copy the ORDER objects pointed to by the elements of the 'order' array in the copy constructor of Item_func_group_concat. sql/table.h: Removed the unused 'item_copy' member of the ORDER class.
* | Manual merge of mysql-5.1-bugteam into mysql-trunk-merge.Alexey Kopytov2010-04-031-0/+12
|\ \ | |/ | | | | | | | | | | | | | | Conflicts: Text conflict in mysql-test/suite/binlog/r/binlog_row_mix_innodb_myisam.result Text conflict in sql/log.cc Text conflict in sql/set_var.cc Text conflict in sql/sql_class.cc
| * Fix for bug#52397: another crash with explain extended and group_concatRamil Kalimullin2010-03-311-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: EXPLAIN EXTENDED was trying to resolve references to freed temporary table fields for GROUP_CONCAT()'s ORDER BY arguments. Fix: use stored original GROUP_CONCAT()'s arguments in such a case. mysql-test/r/func_gconcat.result: Fix for bug#52397: another crash with explain extended and group_concat - test result. mysql-test/t/func_gconcat.test: Fix for bug#52397: another crash with explain extended and group_concat - test case. sql/item_sum.cc: Fix for bug#52397: another crash with explain extended and group_concat - use "pargs", printing ORDER BY arguments in the Item_func_group_concat::print() instead of "order" to avoid possible reference resolving to (freed) temporary table fields.
* | Manual merge of mysql-5.1-bugteam to mysql-trunk-merge.Alexey Kopytov2010-02-231-0/+15
|\ \ | |/ | | | | | | | | | | | | | | Conflicts: Text conflict in client/mysqltest.cc Text conflict in configure.in Text conflict in mysql-test/include/mtr_warnings.sql
| * manual mergeTatiana A. Nurnberg2010-02-191-0/+15
| |\
| | * Bug#49487: crash with explain extended and group_concat in a derived tableTatiana A. Nurnberg2010-02-191-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When EXPLAIN EXTENDED tries to print column names, it checks whether the referenced table is CONST (in which case, the column's value rather than its name will be printed). If no proper table is reference (i.e. because a derived table was used that has since gone out of scope), this will fail spectacularly. This ports an equivalent of the fix for Bug 43354. mysql-test/r/func_gconcat.result: Show that EXPLAIN EXTENDED on a GROUP_CONCAT() on a derived table no longer crashes the server. mysql-test/t/func_gconcat.test: Show that EXPLAIN EXTENDED on a GROUP_CONCAT() on a derived table no longer crashes the server. sql/item_sum.cc: Do not de-ref what cannot be, that is, temp-tables that have gone away. This is of questionable utility anyway, since our deref has the sole purpose of checking whether the table is const (in which case, we'll substitute the column with its value in EXPLAIN EXTENDED - that is all).
* | | WL#2110 (SIGNAL)Marc Alff2009-09-101-0/+32
|/ / | | | | | | | | | | | | | | WL#2265 (RESIGNAL) Manual merge of SIGNAL and RESIGNAL to mysql-trunk-signal, plus required dependencies.
* | Merge magare.gmz:/home/kgeorge/mysql/work/B35298-5.0-bugteamunknown2008-05-011-0/+36
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | into magare.gmz:/home/kgeorge/mysql/work/B35298-5.1-bugteam mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Auto merged configure.in: merge 5.0-bugteam to 5.1-bugteam
| * Fix for bug #35298: GROUP_CONCAT with DISTINCT can crash the serverunknown2008-05-011-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The bug is a regression introduced by the patch for bug32798. The code in Item_func_group_concat::clear() relied on the 'distinct' variable to check if 'unique_filter' was initialized. That, however, is not always valid because Item_func_group_concat::setup() can do shortcuts in some cases w/o initializing 'unique_filter'. Fixed by checking the value of 'unique_filter' instead of 'distinct' before dereferencing. mysql-test/r/func_gconcat.result: Added test cases for bugs #35298 and #36024. mysql-test/t/func_gconcat.test: Added test cases for bugs #35298 and #36024. sql/item_sum.cc: Check if unique_filter != NULL before dereferencing it. Non-zero value of distinct does not always mean that unique_filter is initialized because Item_func_group_concat::setup() can do shortcuts is some cases
* | Merge magare.gmz:/home/kgeorge/mysql/work/B34747-5.0-optunknown2008-02-281-0/+17
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into magare.gmz:/home/kgeorge/mysql/work/B34747-5.1-opt libmysql/libmysql.c: Auto merged libmysqld/lib_sql.cc: Auto merged mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Auto merged sql/log.cc: Auto merged sql/sql_yacc.yy: Auto merged mysql-test/r/subselect.result: merged bug 34747 and 33266 5.0-opt->5.1-opt mysql-test/t/subselect.test: merged bug 34747 and 33266 5.0-opt->5.1-opt
| * Bug #34747: crash in debug assertion check after derived tableunknown2008-02-281-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Was a double-free of the Unique member of Item_func_group_concat. This was not causing a crash because the Unique is a descendent of Sql_alloc. Fixed to free the Unique only if it was allocated for the instance of Item_func_group_concat it was referenced from mysql-test/r/func_gconcat.result: Bug #34747: test case mysql-test/t/func_gconcat.test: Bug #34747: test case sql/item_sum.cc: Bug #34747: free the Unique only if it was allocated for this instance of Item_func_group_concat
| * Merge mhansson@bk-internal:/home/bk/mysql-5.0-optunknown2007-12-151-0/+41
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into linux-st28.site:/home/martin/mysql/src/bug32798-united/my50-bug32798-united-push sql/item_sum.cc: Auto merged mysql-test/r/func_gconcat.result: Bug#32798: Manual merge. mysql-test/t/func_gconcat.test: Bug#32798: Manual merge.
* | \ Merge mhansson@bk-internal:/home/bk/mysql-5.1-optunknown2007-12-151-0/+41
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into linux-st28.site:/home/martin/mysql/src/bug32798-united/my51-bug32798-united-push sql/item_sum.cc: Auto merged mysql-test/r/func_gconcat.result: Bug#32798: Manual merge. mysql-test/t/func_gconcat.test: Bug#32798: Manual merge.
| * \ \ Merge ↵unknown2007-12-141-0/+43
| |\ \ \ | | | |/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | linux-st28.site:/home/martin/mysql/src/bug32798-united/my50-bug32798-united into linux-st28.site:/home/martin/mysql/src/bug32798-united/my51-bug32798-united mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Manual merge, Field::cmp has argument type const uchar* in 5.1 sql/item_sum.h: manual merge
| | * | Bug#32798: DISTINCT in GROUP_CONCAT clause fails when ordering by a column unknown2007-12-141-0/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | with null values For queries containing GROUP_CONCAT(DISTINCT fields ORDER BY fields), there was a limitation that the DISTINCT fields had to be the same as ORDER BY fields, owing to the fact that one single sorted tree was used for keeping track of tuples, ordering and uniqueness. Fixed by introducing a second structure to handle uniqueness so that the original structure has only to order the result. mysql-test/r/func_gconcat.result: Bug#32798: - Wrong test result turned correct after fix. - Correct test result mysql-test/t/func_gconcat.test: Bug#32798: Test case sql/item_sum.cc: Bug#32798: Implementation of fix. Dead code removal. - removed comment describing this bug - replaced body of function group_concat_key_cmp_with_distinct - removed function group_concat_key_cmp_with_distinct_and_order - Added a Unique object to maintain uniqueness of values. sql/item_sum.h: Bug#32798: Declarations and comments.
* | | | Merge mysql.com:/home/gluh/MySQL/Merge/5.0-optunknown2007-10-291-0/+9
|\ \ \ \ | | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into mysql.com:/home/gluh/MySQL/Merge/5.1-opt mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Auto merged
| * | | Bug#30897 GROUP_CONCAT returns extra comma on empty fieldsunknown2007-10-291-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fix is a copy of Martin Friebe's suggestion. added testing for no_appended which will be false if anything, including the empty string is in result mysql-test/r/func_gconcat.result: test result mysql-test/t/func_gconcat.test: test case sql/item_sum.cc: added testing for no_appended which will be False if anything, including the empty string is in result
* | | | Merge mysql.com:/home/ram/work/b31154/b31154.5.0unknown2007-10-151-0/+28
|\ \ \ \ | |/ / / | | / / | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | into mysql.com:/home/ram/work/b31154/b31154.5.1 mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Auto merged
| * | Fix for bug #31154: field.h:1649: virtual int Field_bit::cmp(const uchar*, ↵unknown2007-10-111-0/+28
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | const uchar*): Assertion Problem: GROUP_CONCAT(DISTINCT BIT_FIELD...) uses a tree to store keys; which are constructed using a temporary table fields, see Item_func_group_concat::setup(). As a) we don't store null bits in the tree where the bit fields store parts of their data and b) there's no method to properly compare two table records we've got problem. Fix: convert BIT fields to INT in the temporary table used. mysql-test/r/func_gconcat.result: Fix for bug #31154: field.h:1649: virtual int Field_bit::cmp(const uchar*, const uchar*): Assertion - test result. mysql-test/t/func_gconcat.test: Fix for bug #31154: field.h:1649: virtual int Field_bit::cmp(const uchar*, const uchar*): Assertion - test case. sql/item_sum.cc: Fix for bug #31154: field.h:1649: virtual int Field_bit::cmp(const uchar*, const uchar*): Assertion - force the create_tmp_table() to convert BIT columns to INT in order to be able to compare records containing BIT fields.
* | Merge gleb.loc:/home/uchum/work/bk/5.0-optunknown2007-07-201-0/+11
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | into gleb.loc:/home/uchum/work/bk/5.1-opt mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/item_sum.cc: Auto merged
| * Bug#29850: Wrong charset of GROUP_CONCAT result when the select employsunknown2007-07-191-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a temporary table. The result string of the Item_func_group_concat wasn't initialized in the copying constructor of the Item_func_group_concat class. This led to a wrong charset of GROUP_CONCAT result when the select employs a temporary table. The copying constructor of the Item_func_group_concat class now correctly initializes the charset of the result string. mysql-test/t/func_gconcat.test: Added a test case for the bug#29850: Wrong charset of the GROUP_CONCAT result when the select employs a temporary table. mysql-test/r/func_gconcat.result: Added a test case for the bug#29850: Wrong charset of the GROUP_CONCAT result when the select employs a temporary table. sql/item_sum.cc: Bug#29850: Wrong charset of GROUP_CONCAT result when the select employs a temporary table. The copying constructor of the Item_func_group_concat class now correctly initializes the charset of the result string.
| * Merge dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/my50-bug23856unknown2007-05-221-0/+30
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/mysql-5.0o-pushee sql/item_sum.cc: Auto merged sql/sql_select.cc: Auto merged mysql-test/r/func_gconcat.result: Bug#23856: Manually merged mysql-test/t/func_gconcat.test: Bug#23856: Manually merged
* | \ Merge dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/my51-bug23856unknown2007-05-221-0/+30
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/mysql-5.1o-pushee sql/item_sum.cc: Auto merged sql/sql_select.cc: Auto merged mysql-test/r/func_gconcat.result: Bug#23856: Manually merged test case. mysql-test/t/func_gconcat.test: Bug#23856: Manually merged test case.
| * \ \ Merge dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/my50-bug23856unknown2007-05-211-0/+32
| |\ \ \ | | | |/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into dl145s.mysql.com:/users/mhansson/mysql/push/bug23856/my51-bug23856 mysql-test/r/func_gconcat.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged sql/field.h: Auto merged sql/field_conv.cc: Auto merged sql/sql_select.cc: Auto merged sql/item_sum.cc: Bug#23856: Manual merge 5.0->5.1. Changed comparison to strict inequality between convert_blob_length and UINT_MAX16. Replaced UINT_MAX16 with Field_varstring::MAX_SIZE.
| | * | bug#23856unknown2007-05-211-0/+32
| | | |
* | | | Merge mysql.com:/d2/hf/mrg/mysql-5.0-optunknown2007-05-181-0/+14
|\ \ \ \ | |/ / / |/| | / | | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into mysql.com:/d2/hf/mrg/mysql-5.1-opt mysql-test/r/func_gconcat.result: Auto merged mysql-test/include/mix1.inc: Auto merged mysql-test/r/func_group.result: Auto merged mysql-test/r/innodb_mysql.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged mysql-test/t/func_group.test: Auto merged sql/item.cc: Auto merged sql/item_cmpfunc.cc: Auto merged sql/item_sum.cc: Auto merged sql/sql_select.cc: Auto merged sql/sql_union.cc: Auto merged mysql-test/r/ps.result: merging mysql-test/r/subselect.result: merging mysql-test/r/type_datetime.result: SCCS merged mysql-test/t/ps.test: merging mysql-test/t/subselect.test: merging mysql-test/t/type_datetime.test: merging sql/opt_sum.cc: SCCS merged
| * | bug#28273: GROUP_CONCAT and ORDER BY: No warning when result gets truncated.unknown2007-05-111-0/+14
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using GROUP_CONCAT with ORDER BY, a tree is used for the sorting, as opposed to normal nested loops join used when there is no ORDER BY. The tree traversal that generates the result counts the lines that have been cut down. (as they get cut down to the field's max_size) But the check of that count was before the tree traversal, so no warning was generated if the output is truncated. Fixed by moving the check to after the tree traversal. mysql-test/r/func_gconcat.result: bug#28273: correct result mysql-test/t/func_gconcat.test: bug#28273: test case sql/item_sum.cc: bug#28273: the fix Moved the code that outputs a warning to after temporary table (tree) is traversed.
* | Merge moonbone.local:/mnt/gentoo64/work/bk-trees/mysql-5.0-optunknown2007-03-311-1/+11
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into moonbone.local:/mnt/gentoo64/work/bk-trees/mysql-5.1-opt mysql-test/r/func_gconcat.result: Auto merged mysql-test/r/insert_update.result: Auto merged mysql-test/r/subselect3.result: Auto merged mysql-test/t/func_gconcat.test: Auto merged mysql-test/t/insert_update.test: Auto merged sql/field_conv.cc: Auto merged sql/item.cc: Auto merged sql/sql_base.cc: Auto merged sql/sql_load.cc: Auto merged sql/sql_select.cc: Auto merged sql/table.h: Auto merged mysql-test/r/gis.result: Manual merge mysql-test/t/gis.test: Manual merge sql/handler.cc: Manual merge sql/item_sum.cc: Manual merge sql/sql_insert.cc: Manual merge sql/sql_table.cc: Manual merge
| * Bug #26815:unknown2007-03-271-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When creating a temporary table the concise column type of a string expression is decided based on its length: - if its length is under 512 it is stored as either varchar or char. - otherwise it is stored as a BLOB. There is a flag (convert_blob_length) to create_tmp_field that, when >0 allows to force creation of a varchar if the max blob length is under convert_blob_length. However it must be verified that convert_blob_length (settable through a SQL option in some cases) is under the maximum that can be stored in a varchar column. While performing that check for expressions in create_tmp_field_from_item the max length of the blob was used instead. This causes blob columns to be created in the heap temp table used by GROUP_CONCAT (where blobs must not be created in the temp table because of the constant convert_blob_length that is passed to create_tmp_field() ). And since these blob columns are not expected in that place we get wrong results. Fixed by checking that the value of the flag variable is in the limits that fit into VARCHAR instead of the max length of the blob column. mysql-test/r/func_gconcat.result: Bug #26815: test case mysql-test/t/func_gconcat.test: Bug #26815: test case sql/item_sum.cc: Bug #26815: wrong length was checked sql/sql_select.cc: Bug #26815: wrong length was checked