Skip to content

Instantly share code, notes, and snippets.

@thisismzm
Created May 12, 2018 05:12
Show Gist options
  • Save thisismzm/d588f89adcf66257b04736c74da55689 to your computer and use it in GitHub Desktop.
Save thisismzm/d588f89adcf66257b04736c74da55689 to your computer and use it in GitHub Desktop.
Disable NO_ZERO_IN_DATE,NO_ZERO_DATE modes in sql
set sql_mode="ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION";
set global sql_mode="ONLY_FULL_GROUP_BY,STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION";
@thisismzm
Copy link
Author

You can view your sql modes with the following command:
show variables like 'sql_mode' ;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment