Skip to content

Commit

Permalink
[parser] mysql: update sql-mode default (pingcap#45)
Browse files Browse the repository at this point in the history
Change TiDB to use same default as MySQL 5.7
  • Loading branch information
morgo authored Jan 6, 2019
1 parent abb0e02 commit dbe1c14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion parser/mysql/const.go
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ var AllColumnPrivs = []PrivilegeType{SelectPriv, InsertPriv, UpdatePriv}
const AllPrivilegeLiteral = "ALL PRIVILEGES"

// DefaultSQLMode for GLOBAL_VARIABLES
const DefaultSQLMode = "ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"
const DefaultSQLMode = "ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

// DefaultLengthOfMysqlTypes is the map for default physical length of MySQL data types.
// See http://dev.mysql.com/doc/refman/5.7/en/storage-requirements.html
Expand Down

0 comments on commit dbe1c14

Please sign in to comment.