Skip to content

Instantly share code, notes, and snippets.

@petemcw
Created September 7, 2011 22:04
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save petemcw/1201928 to your computer and use it in GitHub Desktop.
Save petemcw/1201928 to your computer and use it in GitHub Desktop.
MySQL user creation
GRANT USAGE ON *.* TO `user`@`localhost` IDENTIFIED BY 'password';
GRANT CREATE ROUTINE, CREATE VIEW, ALTER, SHOW VIEW, CREATE, ALTER ROUTINE, INSERT, SELECT, DELETE, UPDATE, DROP, LOCK TABLES, CREATE TEMPORARY TABLES, INDEX ON `database`.* TO `user`@`localhost` IDENTIFIED BY 'password';
FLUSH PRIVILEGES;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment