in reply to [OT] Re: Another Endless Loop
in thread Another Endless Loop

... I am particularly offended by the message Query OK, when it clearly isn't.

I agree with you that this is questionable default behaviour, but at least it's documented, and (as of version 5.0.2) it seems you can enable a "strict mode" to have it error out:

"If you assign a value to a CHAR or VARCHAR column that exceeds the column's maximum length, the value is truncated to fit. If the truncated characters are not spaces, a warning is generated. For truncation of non-space characters, you can cause an error to occur (rather than a warning) and suppress insertion of the value by using strict SQL mode. See Section 5.2.6, "SQL Modes"."

Replies are listed 'Best First'.
Re^2: [OT] Re: Another Endless Loop
by samtregar (Abbot) on Feb 24, 2007 at 23:48 UTC
    Awesome. I was hoping strict mode would do that. We're going to v5.x soon and I'm definitely going to want to turn that on!

    -sam

      There are a ton of strictnesses you can enable. You should read up on them here

      My criteria for good software:
      1. Does it work?
      2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?