By default, MySQL 8.0 rejects invalid or improper data values and aborts the statement in which they occur. 默认情况下,MySQL 8.0会拒绝无效或不正确的数据值,并中止出现这些值的语句。It is possible to alter this behavior to be more forgiving of invalid values, such that the server coerces them to valid ones for data entry, by disabling strict SQL mode (see Section 5.1.11, “Server SQL Modes”), but this is not recommended.可以通过禁用严格的SQL模式(请参阅第5.1.11节,“服务器SQL模式”)来更改此行为,以更宽容地容忍无效值,从而使服务器强制将其转换为有效值以进行数据输入,但不建议这样做。
Older versions of MySQL employed the forgiving behavior by default; for a description of this behavior, see Constraints on Invalid Data.MySQL的旧版本默认采用宽容行为;有关此行为的描述,请参阅对无效数据的约束。