On Thu 2003-03-20 at 14:01:52 -0500, [EMAIL PROTECTED] wrote: > I have a table with a column defined as the following. > > hash CHAR(16) BINARY NOT NULL > > Most data inserts fine. However, if data has trailing white space > (ASCII character 32), it seems to be getting truncated by MySQL during > the insert, such that subsequent queries to find the values fail. Full > example below. > > Any Ideas?
That is the documented behaviour (http://www.mysql.com/doc/en/CHAR.html) and is an (implementation dependend) feature of SQL. If you don't want it, you had to use VARCHAR instead. But there is a known bug with MySQL (see above and http://www.mysql.com/doc/en/Open_bugs.html). As the bug description implies, use a TEXT type like TINYTEXT instead. HTH, Benjamin. PS: Btw, the BINARY keyword only influences sort behaviour, nothing else. -- [EMAIL PROTECTED] --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php