Posts

Showing posts with the label homebrew

Homebrew Install Mysql and Connect to Workbentch

Install MySql in MacOS Seirra can be done as follows. brew install mysql brew services start mysql mysqladmin -u root password 'newpassword' Login ; mysql -u root -p  Get Config Location : mysql --help | grep cnf Config Path :  export MYSQL_PATH=/usr/local/Cellar/mysql/8.0.12  PATH=$MYSQL_PATH/bin:$PATH Connect Squrel if you filed to collect  with mysql as follows :   MySQL said: Authentication plugin 'caching_sha2_password' cannot be loaded: dlopen(/usr/local/lib/plugin/caching_sha2_password.so, 2): image not found https://stackoverflow.com/questions/51179516/sequel-pro-and-mysql-connection-failed Go to my.cnf file and in section   [mysqld]   add line: default-authentication-plugin=mysql_native_password . Then, login to mysql server from terminal and run   mysql -u root -p , then inside shell execute this command:   ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '<password>'; ex...

Remove MySql Strick Mode

Image
I have installed MySql in my Mac OSx using home brew. However when I was going to execute query like below it iilll gives a error Query : `comment_date` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', Error :  #1067 - Invalid default value for 'comment_date' The reason is My Sql has been installed in Strict mode Where User could not do some database actions ,which are prmiited in old version. This  article helps to remove strict mode permemtly as well as tempory  : http://nickbartlett.com/how- to-turn-off-mysql-strict-mode/ Simply run the query with following in the begin SET @@global.sql_mode= ”;