On 1/1/03 5:46 PM, "Richard Nagle" <[EMAIL PROTECTED]> wrote:
> Well it would appear that I finally have a connection Congrats. > q. since I am root, do I still need to GRANT a database to myself? > or just a to a new user. aka: bob@localhost If you are the only person using the computer that the mysql server runs on then theoretically you don't need to create any other user you don't even need a password for root then. But it is generally not a good thing to do things as root user if you don't have to (and you don't for most of the time) in Unix and in Mysql. Thus I strongly recommend that you do your database tutorials as a non root user for example as bob@localhost as you suggested. Lets say the database in your tutorial is called 'tutorialdb' you would do the following: shell> mysql -u root -p password: mysql> CREATE DATABASE tutorialdb; mysql> GRANT ALL ON tutorialdb.* to bob@localhost; mysq> quit; This would give you (well bob@localhost) all priviliges (except GRANT) on the tutorialdb and all tables in this database when you are using the socket connection i.e. You are logged in and call mysql on the machine that runs the mysql server (mysqld). shell> mysql -u bob mysql> use tutorialdb; Or shell> mysql -u bob -D tutorialdb As you see bob can login without a password, which maybe what you want. If not you can either set a password now or change the GRANT command that you used in the first place to (replace pass with the password you like - the quotes are part of the command syntax: mysql> GRANT ALL ON tutorialdb.* to bob@localhost IDENTIFIED BY 'pass'; HTH/h --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php