{"id":156,"date":"2016-06-28T17:13:30","date_gmt":"2016-06-28T17:13:30","guid":{"rendered":"http:\/\/www.mfitri.net\/site\/?p=156"},"modified":"2018-07-05T13:31:17","modified_gmt":"2018-07-05T13:31:17","slug":"mysql-strict-mode-centos-7","status":"publish","type":"post","link":"https:\/\/www.mfitri.net\/site\/mysql-strict-mode-centos-7\/","title":{"rendered":"Mysql strict Mode centos 7"},"content":{"rendered":"<p>By default (Cpanel centos 7) enable Mysql strict mode<\/p>\n<p>You can check from SSH by this command :<\/p>\n<p>&nbsp;<\/p>\n<p>[shell]mysql -e &#8216;select @@GLOBAL.sql_mode;'[\/shell]<\/p>\n<p>&nbsp;<\/p>\n<p>The result :<\/p>\n<p>[shell]+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+<br \/>\n| @@GLOBAL.sql_mode |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+<br \/>\n| STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION |<br \/>\n+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+[\/shell]<\/p>\n<p>&nbsp;<\/p>\n<p>If you familiar with Cpanel Mysql configuration location is \/etc\/my.cnf<\/p>\n<p>BUT in centos 7, the configuration for strict mode is from this location = \/usr\/my.cnf<\/p>\n<p>NOW you have to edit \/usr\/my.cnf to<\/p>\n<p>[shell]sql_mode=&#8221;&#8221;[\/shell]<\/p>\n<p>After that :<\/p>\n<p>[shell]systemctl restart mysql.service[\/shell]<\/p>\n<p>&nbsp;<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>By default (Cpanel centos 7) enable Mysql strict mode You can check from SSH by this command : &nbsp; [shell]mysql -e &#8216;select @@GLOBAL.sql_mode;'[\/shell] &nbsp; The result : [shell]+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+ | @@GLOBAL.sql_mode | +&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+ | STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION | +&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+[\/shell] &nbsp; If you familiar with Cpanel Mysql configuration location is \/etc\/my.cnf BUT in centos 7, the configuration for strict mode is from this location<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-156","post","type-post","status-publish","format-standard","hentry","category-ilmu"],"_links":{"self":[{"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/posts\/156","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/comments?post=156"}],"version-history":[{"count":5,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/posts\/156\/revisions"}],"predecessor-version":[{"id":177,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/posts\/156\/revisions\/177"}],"wp:attachment":[{"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/media?parent=156"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/categories?post=156"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.mfitri.net\/site\/wp-json\/wp\/v2\/tags?post=156"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}