Skip to content
Thierry Lam edited this page Oct 20, 2023 · 7 revisions
  • sudo apt-get install mysql
  • If the mysql database is not created, a root password need to be set. Run mysql_secure_installation and set a password for root.
  • grant all privileges on *.* to 'someuser'@'localhost' with grant option;

MySQL-python on Mac

  1. Symlink the mysql under /usr/local/
  2. Add export DYLD_LIBRARY_PATH=/usr/local/mysql/lib/ to .bash_profile
  3. Download and install MySQL-python

Triggers

Running triggers from mysql cli or Sequel Pro:

DROP TRIGGER my_table_update

DELIMITER $$
CREATE TRIGGER my_table_update BEFORE UPDATE ON my_table
              FOR EACH ROW
              BEGIN
                  IF (OLD.name != NEW.name) THEN
                      SET NEW.update=1;
                  END IF;
              END$$
DELIMITER ;

Simple GUI for Mac

https://github.com/Sequel-Ace/Sequel-Ace

Clone this wiki locally