summaryrefslogtreecommitdiff
path: root/sql/sql_string.cc
Commit message (Collapse)AuthorAgeFilesLines
* auto-mergeIgnacio Galarza2009-03-191-11/+8
|\
| * Merge from dev tree.Alexey Kopytov2009-02-141-2/+2
| |\
| | * Fix for bug #21205: Different number of digits for float/double/real in ↵Alexey Kopytov2009-01-281-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --ps-protocol Various parts of code used different 'precision' arguments for sprintf("%g") when converting floating point numbers to a string. This led to differences in results in some cases depending on whether the text-based or prepared statements protocol is used for a query. Fixed by changing arguments to sprintf("%g") to always be 15 (DBL_DIG) so that results are consistent regardless of the protocol. This patch will be null-merged to 6.0 as the problem does not exists there (fixed by the patch for WL#2934).
| * | Fix for bug #41868: crash or memory overrun with concat + upper,Alexey Kopytov2009-02-101-9/+6
| |/ | | | | | | | | | | | | | | date_format functions String::realloc() did not check whether the existing string data fits in the newly allocated buffer for cases when reallocating a String object with external buffer (i.e.alloced == FALSE). This could lead to memory overruns in some cases.
* | Bug#29125 Windows Server X64: so many compiler warningsIgnacio Galarza2009-02-101-2/+2
|/ | | | | - Remove bothersome warning messages. This change focuses on the warnings that are covered by the ignore file: support-files/compiler_warnings.supp. - Strings are guaranteed to be max uint in length
* Merge dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rplmkindahl@dl145h.mysql.com2007-12-191-2/+2
|\ | | | | | | into dl145h.mysql.com:/data0/mkindahl/mysql-5.0-rpl-merge
| * sql_string.cc:bar@mysql.com/bar.myoffice.izhnet.ru2007-12-051-2/+2
| | | | | | | | Fixing a wrong comment.
* | Fixed bug #32282: TEXT silently truncates when value is exactly 65536gshchepa/uchum@gleb.loc2007-11-191-1/+4
|/ | | | | | | | bytes length. The server has been modified to report warnings on truncation to 65536 bytes as usual.
* Reversing additional change suggested by Sergbar@mysql.com/bar.myoffice.izhnet.ru2007-08-071-2/+0
| | | | | | | | | under terms of bug#28875 for better performance. The change appeared to require more changes in item_cmpfunc.cc, which is dangerous in 5.0. Conversion between a latin1 column and an ascii string constant stopped to work.
* Bug#28875 Conversion between ASCII and LATIN1 charsets does not functionbar@mysql.com/bar.myoffice.izhnet.ru2007-08-031-0/+2
| | | | | | | | | | | (Regression, caused by a patch for the bug 22646). Problem: when result type of date_format() was changed from binary string to character string, mixing date_format() with a ascii column in CONCAT() stopped to work. Fix: - adding "repertoire" flag into DTCollation class, to mark items which can return only pure ASCII strings. - allow character set conversion from pure ASCII to other character sets.
* Merge bk-internal.mysql.com:/home/bk/mysql-5.0monty@mysql.com/narttu.mysql.fi2007-01-221-10/+9
|\ | | | | | | into mysql.com:/home/my/mysql-5.0
| * Fixed compiler warnings detected by option -Wshadow and -Wunused:monty@mysql.com/narttu.mysql.fi2006-12-151-10/+9
| | | | | | | | | | | | | | | | | | | | | | | | - Removed not used variables and functions - Added #ifdef around code that is not used - Renamed variables and functions to avoid conflicts - Removed some not used arguments Fixed some class/struct warnings in ndb Added define IS_LONGDATA() to simplify code in libmysql.c I did run gcov on the changes and added 'purecov' comments on almost all lines that was not just variable name changes
* | Merge bk-internal.mysql.com:/home/bk/mysql-5.0kostja@bodhi.local2007-01-111-2/+2
|\ \ | | | | | | | | | into bodhi.local:/opt/local/work/mysql-5.0-runtime
| * | Fix for BUG#24293: '\Z' token is not handled correctly in views.anozdrin/alik@alik.2006-12-191-2/+2
| |/ | | | | | | | | | | | | | | | | | | | | If SELECT-part of CREATE VIEW statement contains '\Z', it is not handled correctly. The problem was in String::print(). Symbol with code 032 (26) is replaced with '\z', which is not supported by the lexer. The fix is to replace the symbol with '\Z'.
* | Many files:kent@mysql.com/kent-amd64.(none)2006-12-231-2/+1
|/ | | | Changed header to GPL version 2 only
* Bug#18908: ERROR 1406 (22001): Data too long for column :: using utf8bar@mysql.com/bar.intranet.mysql.r18.ru2006-10-301-0/+156
| | | | | | | | | Problem: Too confusing error message when cannot convert between string and column character sets on INSERT and UPDATE. Fix: producing a better error message, instead of "Data too long" in such cases Additional changes: Adding "DROP TABLE IF EXISTS" into several tests to be safe against failures in previous tests.
* Merge salvation.intern.azundris.com:/home/tnurnberg/21913/my41-21913tnurnberg@salvation.intern.azundris.com2006-09-041-1/+6
|\ | | | | | | | | | | | | | | | | | | | | | | into salvation.intern.azundris.com:/home/tnurnberg/21913/my50-21913 21913: DATE_FORMAT() Crashes mysql server if I use it through mysql-connector-j driver. Variable character_set_results can legally be NULL (for "no conversion.") This could result in a NULL deref that crashed the server. Fixed. (Although ran some additional precursory tests to see whether I could break anything else, but no breakage so far.)
| * Bug#21913: DATE_FORMAT() Crashes mysql server if I use it through ↵tnurnberg@salvation.intern.azundris.com2006-09-041-1/+6
| | | | | | | | | | | | | | | | | | | | mysql-connector-j driver. Variable character_set_results can legally be NULL (for "no conversion.") This could result in a NULL deref that crashed the server. Fixed. (Although ran some additional precursory tests to see whether I could break anything else, but no breakage so far.)
* | Merge mysql.com:/usr/home/bar/mysql-4.1.b15376bar@mysql.com2006-03-231-1/+11
|\ \ | |/ | | | | into mysql.com:/usr/home/bar/mysql-5.0
| * Bug#15375 Unassigned multibyte codes are brokenbar@mysql.com2005-12-121-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into parts when converting to Unicode. m_ctype.h: Reorganizing mb_wc return codes to be able to return "an unassigned N-byte-long character". sql_string.cc: Adding code to detect and properly handle unassigned characters (i.e. the those character which are correctly formed according to the character specifications, but don't have Unicode mapping). Many files: Fixing conversion function to return new codes. ctype_ujis.test, ctype_gbk.test, ctype_big5.test: Adding a test case. ctype_ujis.result, ctype_gbk.result, ctype_big5.result: Fixing results accordingly.
* | Inefficient usage of String::append() fixed.bell@sanja.is.com.ua2005-11-201-6/+6
| | | | | | | | | | | | | | Bad examples of usage of a string with its length fixed. The incorrect length in the trigger file configuration descriptor fixed (BUG#14090). A hook for unknown keys added to the parser to support old .TRG files.
* | Merge with 4.1monty@mysql.com2005-06-071-2/+1
|\ \ | |/
| * a compiler must see '#pragma implementation' *before*serg@serg.mylan2005-06-051-1/+2
| | | | | | | | '#pragma interface' (that comes with the #include'd header file)
| * Move USE_PRAGMA_IMPLEMENTATION to proper placemonty@mysql.com2005-06-031-2/+0
| | | | | | | | | | | | Ensure that 'null_value' is not accessed before val() is called in FIELD() functions Fixed initialization of key maps. This fixes some problems with keys when you have more than 64 keys Fixed that ROLLUP don't always create a temporary table. This fix ensures that func_gconcat.test results are now predictable
* | Mergekent@mysql.com2005-06-021-1/+2
|\ \ | |/
| * tztime.cc:kent@mysql.com2005-06-021-1/+2
| | | | | | | | | | | | Set #pragma implementation" earlier Many files: Need to include <my_global.h> before #ifdef USE_PRAGMA_IMPLEMENTATION
* | Merge from 4.1msvensson@neptunus.(none)2005-05-261-1/+1
|\ \ | |/
| * Add ifdefs to control when "#pragma implementation" should be usedmsvensson@neptunus.(none)2005-05-261-1/+1
| | | | | | | | Added some more ifdefs for "#pragma interface"
* | Cleanup during reviewsmonty@mysql.com2005-03-161-6/+6
| | | | | | | | | | Removed some optional arguments Fixed portability problem in federated tests
* | Add support for up to VARCHAR (size up to 65535)monty@mysql.com2004-12-061-2/+2
| | | | | | | | | | | | | | | | | | Renamed HA_VAR_LENGTH to HA_VAR_LENGTH_PART Renamed in all files FIELD_TYPE_STRING and FIELD_TYPE_VAR_STRING to MYSQL_TYPE_STRING and MYSQL_TYPE_VAR_STRING to make it easy to catch all possible errors Added support for VARCHAR KEYS to heap Removed support for ISAM Now only long VARCHAR columns are changed to TEXT on demand (not CHAR) Internal temporary files can now use fixed length tables if the used VARCHAR columns are short
* | Merge with 4.1 to get in latest bug fixesmonty@mysql.com2004-11-041-12/+16
|\ \ | |/
| * fix call of string::copy() if HAVE_FCONVERT is settomas@poseidon.ndb.mysql.com2004-11-011-1/+2
| |
| * A fix according to Monty's request:bar@mysql.com2004-10-291-11/+14
| | | | | | | | | | "uint *errors" is now a non-optional parameter in String:copy() and copy_and_convert().
* | merge with 4.1monty@mysql.com2004-10-291-5/+19
|\ \ | |/
| * Produce a "truncated" warning if a value cannot be convertedbar@mysql.com2004-10-281-4/+17
| | | | | | | | into the column character set on INSERT/UPDATE.
| * Review of all code pushed since last reviewmonty@mishka.local2004-10-201-1/+2
| | | | | | | | | | | | | | Simple optimzations and cleanups Removed compiler warnings and fixed portability issues Added client functions 'mysql_embedded()' to allow client to check if we are using embedded server Fixes for purify
* | Merge with 4.1.3-betamonty@mysql.com2004-07-071-2/+1
|\ \ | |/
| * Critical fixes after review:bar@mysql.com2004-06-161-1/+1
| | | | | | | | | | | | | | - mutex was unlocked before the end of the critical sesion, - Portability issue: It's better to use (*alloc)(x) instead of alloc(x), if alloc is a function passed as an argument. - Use {} around if() block, to avoid possible problems with some Windows compilers.
| * Allocate memory when a character set is requested:bar@mysql.com2004-06-111-1/+1
| | | | | | | | | | | | - For simple character sets: from_uni convertion table. - For UCA: alternative weight arrays. Use mbminlen instead of MY_CS_NONTEXT
| * assert.h needed for my_dbug.h now is included in my_dbug.h, where it for konstantin@mysql.com2004-06-101-1/+0
| | | | | | | | | | some reason wasn't included before. A lot of files cleaned up from #include <assert.h>
* | Merging 4.1 to 5.0.pem@mysql.com2004-05-261-52/+54
|\ \ | |/
| * sql_string.h:bar@bar.intranet.mysql.r18.ru2004-05-251-34/+0
| | | | | | | | | | | | | | Not used code. , sql_string.cc: Not used code.
| * 1. Some optimization when conversion is not needed.bar@bar.intranet.mysql.r18.ru2004-05-251-15/+28
| | | | | | | | | | 2. One now must pass length argument into append(const char *str, uint length), length is not calculated internally anymore.
| * Support for character set conversion in binary protocol: another gokonstantin@mysql.com2004-05-251-11/+34
| | | | | | | | | | | | | | | | | | | | after Monty's review. - Item_param was rewritten. - it turns out that we can't convert string data to character set of connection on the fly, because they first should be written to the binary log. To support efficient conversion we need to rewrite prepared statements binlogging code first.
* | Merge 4.1 -> 5.0pem@mysql.com2004-05-071-1/+1
|\ \ | |/
| * Formatting changes requested by Montymagnus@neptunus.(none)2004-04-151-1/+1
| |
* | Merge 4.1 -> 5.0.pem@mysql.com2004-04-071-19/+60
|\ \ | |/
| * Disable INSERT DELAYED for embedded librarymonty@mysql.com2004-03-291-2/+7
| |
| * Optimized GIS functionsmonty@mashka.mysql.fi2004-03-041-12/+4
| |
| * Merge with public treemonty@mysql.com2004-02-161-4/+49
| |\