Re: mysql data truncation does not cause an error to be thrown
| From: | Andrew Blake | Date: | Thu, 08 Nov 2007 16:13:58 +0000 |
| Subject: | Re: mysql data truncation does not cause an error to be thrown | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-44320@lists.php.net to get a copy of this message | ||
I figured it out
it was the mysql install not php :-)
cheers for your help though :-)
Vandegrift, Ken wrote:
You may want to check the my.ini setting for the table type you are using and see if there is a setting in there that needs to be enabled. I thought I read once that truncation may happen silently depending on the my.ini setting. Just a thought. Ken Vandegrift Shari's Management Corporation Web Developer/Administrator (Direct) 503-605-4132 kvandegrift@sharis.com -----Original Message----- From: Andrew Blake [mailto:a.blake@har.mrc.ac.uk] Sent: Thursday, November 08, 2007 7:51 AM To: Instruct ICC Cc: php-db@lists.php.net Subject: Re: [PHP-DB] mysql data truncation does not cause an error to be thrown Hiya I could check the length of the field against the entry data and javascript myself out of trouble but i was more worried that there is no error or message when mysql clearly returns one saying i've truncated this yet php ignores it completely. It should fail or know about the truncation at least ! Cheers for your reply though :-) Andy Instruct ICC wrote:theUsing mysql_query if i try to force more data than a field can haveyour input before submitting a query?data is truncated yet no error is throw at all. Is there a way round this ? Cheers AndyThis isn't exactly what you want to hear, but how about validating_________________________________________________________________ Boo! Scare away worms, viruses and so much more! Try Windows LiveOneCare! http://onecare.live.com/standard/en-us/purchase/trial.aspx?s_cid=wl_hotm ailnews