| List: | General Discussion | « Previous MessageNext Message » | |
| From: | Michael Stassen | Date: | December 6 2005 8:42pm |
| Subject: | Re: CocoaMySQL v0.7b2 Connection Help In-reply-to: <OF10ADBADD.8CAE69DA-ON852570CC.00518684-852570CC.00553443@unimin.com> | ||
| View as plain text | |||
SGreen@stripped wrote: > Responses intermixed. See below... > > untz <untz786@stripped> wrote on 12/02/2005 10:43:41 PM: <snip> >>3. After logging into mysql, I created the following database: >> >>mysql> create database music_development to 'untz'@'localhost' >>identified by 'paintball'; > > MySQL databases do not have the concept of ownership. They are all global. > You only need to say: > > (@mysql CLI prompt) CREATE DATABASE music_development; > > and you can test to see if your create statement worked by running > > (@CLI) SHOW DATABASES; > > If your database is in that list, the command worked. > > You appear to have mixed a CREATE DATABASE with a GRANT statement. To > create a MySQL user you need to use a GRANT statement. If you want to > create a MySQL user account with all normal DB privileges (but still > cannot grant permission to others), this is how I would create the account > and grant access the new database: > > (@CLI) GRANT usage ON *.* to 'untz'@'localhost' IDENTIFIED BY 'xxxxxx'; > (@CLI) GRANT ALL ON music_development to 'untz'@'localhost'; <snip> The db name is optional with GRANT, but the table name is not, so this statement would grant rights to the *table* named music_development in the currently selected db. (Even though I know why this is so, I've always found it a little counter-intuitive, which has led me to make the same mistake a few times.) What Shawn meant to say was GRANT ALL ON music_development.* to 'untz'@'localhost'; which grants rights on all tables in the music_development to untz@localhost. Michael
| Thread | ||
|---|---|---|
| • CocoaMySQL v0.7b2 Connection Help | untz | 3 Dec |
| • Re: CocoaMySQL v0.7b2 Connection Help | SGreen | 3 Dec |
| • recording time of data entry | prathima rao | 4 Dec |
| • Re: recording time of data entry | Cal Evans | 4 Dec |
| • Re: CocoaMySQL v0.7b2 Connection Help | Michael Stassen | 6 Dec |
