List:MySQL ODBC« Previous MessageNext Message »
From:Martin J. Evans Date:February 3 2006 6:14pm
Subject:No data truncation errors
View as plain text  
Hi,

I have mysql-connector 3.51.12 and MySQL 5.0.15.

When I insert into a char column that is too small I don't seem to get a data
truncated error:

create table test (a char(10))
insert into test values ('AAAAAAAAAAAAAAAAAAAAAAAAAAAA')
returns successfully but truncates the data.

When I try this in the mysql browser it returns a data truncated message inside
a little yellow exclamation mark so it would seem MySQL knows the data is
truncated but MyODBC is not telling me. Does anyone know how to make MyODBC
return the correct data truncated error or is this a "feature" requiring a
coding change to MyODBC?

Martin
--
Martin J. Evans
Easysoft Ltd, UK
http://www.easysoft.com

Thread
No data truncation errorsMartin J. Evans3 Feb