For When You Can't Have The Real Thing
[ start | index | login ]
start > mysql > Creating Users

Creating Users

Created by dave. Last edited by dave, 344 days ago. Viewed 2,834 times. #4
[diff] [history] [edit] [rdf]

Previously, in MySQL

To create a user jsmith with password Secret15 and allow them to do anything with the database named accounts, connect to the database with mysql and issue the command:

mysql> grant all on accounts.* to jsmith@localhost identified by 'Secret15';

Update for Mysql 8 or something


You can't indirectly create users through a grant any more.

mysql> create user mydbadmin@'%' identified by 'superSecretPasswordWord';
Query OK, 0 rows affected, 1 warning (0.01 sec)

mysql> grant all privileges on mydb.* to mydbadmin@'%'; Query OK, 0 rows affected (0.00 sec)

no comments | post comment
This is a collection of techical information, much of it learned the hard way. Consider it a lab book or a /info directory. I doubt much of it will be of use to anyone else.

Useful: | Copyright 2000-2002 Matthias L. Jugel and Stephan J. Schmidt