summaryrefslogtreecommitdiff
path: root/sql/item_buff.cc
Commit message (Collapse)AuthorAgeFilesLines
* Bug #55188: GROUP BY, GROUP_CONCAT and TEXT - inconsistent resultsGeorgi Kodinov2010-07-301-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | In order to be able to check if the set of the grouping fields in a GROUP BY has changed (and thus to start a new group) the optimizer caches the current values of these fields in a set of Cached_item derived objects. The Cached_item_str, used for caching varchar and TEXT columns, is limited in length by the max_sort_length variable. A String buffer to store the value with an alloced length of either the max length of the string or the value of max_sort_length (whichever is smaller) in Cached_item_str's constructor. Then, at compare time the value of the string to compare to was truncated to the alloced length of the string buffer inside Cached_item_str. This is all fine and valid, but only if you're not assigning values near or equal to the alloced length of this buffer. Because when assigning values like this the alloced length is rounded up and as a result the next set of data will not match the group buffer, thus leading to wrong results because of the changed alloced_length. Fixed by preserving the original maximum length in the Cached_item_str's constructor and using this instead of the alloced_length to limit the string to compare to. Test case added.
* Doxygenization of comments.cmiller@zippy.cornsilk.net2007-10-111-6/+13
|
* my_strtoll10-x86.s:kent@mysql.com/kent-amd64.(none)2006-12-311-1/+1
| | | | | | | | | | | | | | | | | | | | | Corrected spelling in copyright text Makefile.am: Don't update the files from BitKeeper Many files: Removed "MySQL Finland AB & TCX DataKonsult AB" from copyright header Adjusted year(s) in copyright header Many files: Added GPL copyright text Removed files: Docs/Support/colspec-fix.pl Docs/Support/docbook-fixup.pl Docs/Support/docbook-prefix.pl Docs/Support/docbook-split Docs/Support/make-docbook Docs/Support/make-makefile Docs/Support/test-make-manual Docs/Support/test-make-manual-de Docs/Support/xwf
* Many files:kent@mysql.com/kent-amd64.(none)2006-12-231-2/+1
| | | | Changed header to GPL version 2 only
* Bug#22138: Unhandled NULL caused server crashevgen@moonbone.local2006-10-111-3/+9
| | | | | | | | The Cached_item_decimal::cmp() method wasn't checking for null pointer returned from the val_decimal() of the item being cached. This leads to server crash. The Cached_item_decimal::cmp() method now check for null values.
* Fix for bug#19667 group by a decimal expression yields wrong resultgluh@eagle.intranet.mysql.r18.ru2006-06-151-1/+1
|
* sql_select.cc:igor@rurik.mysql.com2005-07-251-3/+3
| | | | | | | | | | | | | | | | | | Fixed bug #11412. Reversed the patch of cs 1.1934 for the function create_tmp_table. Modified the function to support tem_ref objects created for view fields. item_buff.cc: Fixed bug #11412. Modified implementation of new_Cached_item to support cacheing of view fields. item.h: Fixed bug #11412. Changed implementation of Item_ref::get_tmp_table_field and added Item_ref::get_tmp_table_item to support Item_ref objects created for view fields. view.test, view.result: Added a test case for bug #11412.
* Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-5.0svoj@mysql.com2005-06-221-1/+1
|\ | | | | | | into mysql.com:/home/svoj/devel/mysql/yassl-mysql-5.0
| * WL#2286 - Compile MySQL w/YASSL supportsvoj@mysql.com2005-06-221-1/+1
| | | | | | | | | | Fix GCC 4.0 link failure. Better CXX_VERSION guessing.
* | Manual mergeigor@rurik.mysql.com2005-06-211-2/+2
|\ \ | |/ |/|
| * group_by.result, group_by.test:igor@rurik.mysql.com2005-06-211-2/+2
| | | | | | | | | | | | | | | | Added a test case for bug #11295. item_buff.cc: Fixed bug #11295. This a correction for the patch of bug #11088 that takes into account a possible NULL values of the BLOB column.
* | Merge svojtovich@bk-internal.mysql.com:/home/bk/mysql-5.0svoj@mysql.com2005-06-201-1/+1
|\ \ | | | | | | | | | into mysql.com:/home/svoj/devel/mysql/yassl-mysql-5.0
| * | WL#2286 - Compile MySQL w/YASSL supportsvoj@mysql.com2005-06-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fix for yaSSL link failures with Forte Developer 7, MIPSpro Compilers, Compaq C++. These compilers have problem with implicit template instantiation in archives (libyassl.a, libtaocrypt.a). Instantiate templates explicitly. Fix for yaSSL link failure on powermacg5 (gcc 3.3). When -O3 is specified gcc inlines __cxa_pure_virtual. This is wrong behavior, __cxa_pure_virtual must never be inlined.
* | | renamed:serg@serg.mylan2005-06-151-18/+18
|/ / | | | | | | | | | | Item_buff -> Cached_item Item_arena -> Query_arena TEST_ASSERT -> YYERROR_UNLESS
* | Merge rurik.mysql.com:/home/igor/dev/mysql-4.1-0igor@rurik.mysql.com2005-06-071-1/+1
|\ \ | |/ | | | | into rurik.mysql.com:/home/igor/dev/mysql-5.0-0
| * item_buff.cc:igor@rurik.mysql.com2005-06-071-1/+1
| | | | | | | | Removed an extra space char.
* | Merge rurik.mysql.com:/home/igor/dev/mysql-4.1-0igor@rurik.mysql.com2005-06-071-2/+7
|\ \ | |/ | | | | into rurik.mysql.com:/home/igor/dev/mysql-5.0-0
| * sql_select.cc, item_buff.cc, item.h:igor@rurik.mysql.com2005-06-071-2/+7
| | | | | | | | | | | | | | | | | | Fixed bug #11088: a crash for queries with GROUP BY a BLOB column + COUNT(DISTINCT...) due to an attempt to allocate a too large buffer for the BLOB field. Now the size of the buffer is limited by max_sort_length. group_by.test, group_by.result: Added a test case for bug #11088.
* | Fixed failing test cases 'row.test' when running with --ps-protocolmonty@mysql.com2005-02-151-2/+1
| | | | | | | | Simple optimzations done while reviewing code
* | Precision Math implementationhf@deer.(none)2005-02-091-3/+34
| |
* | Rename: Item::val -> Item::val_real().konstantin@mysql.com2004-11-111-1/+1
|/
* Old style charset() and set_charset() were removed.bar@bar.mysql.r18.ru2003-08-051-1/+1
|
* stringcmp() and sortcmp() have been unifiedbar@bar.mysql.r18.ru2003-03-041-3/+1
| | | | | into the only one sortcmp() with additional CHARSET_INFO *cmp_charset argument.
* Less "default_charset_info"bar@bar.mysql.r18.ru2002-12-191-1/+1
|
* BINARY charset is now used instead of binary_flagbar@bar.mysql.r18.ru2002-10-251-1/+1
|
* Update copyrightmonty@hundin.mysql.fi2001-12-061-3/+3
| | | | Fixed memory leak on shutdown (Affects the embedded version & MyODBC)
* Import changesetbk@work.mysql.com2000-07-311-0/+119