SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Zealot
    Join Date
    Jul 2002
    Location
    USA
    Posts
    132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Please explain Grants & Privileges

    and how users should be setup in phpMyAdmin. If I want user "mycdtca" to be able to run the SQL command "LOAD FILE ..." what do they need to be setup as for "localhost"?

    I keep getting the error "Access denied for user: 'mycdcta@localhost' (Using password: YES)" trying to run the following SQL in a php script.
    Code:
    LOAD DATA INFILE '/home/virtual/site3/fst/var/www/html/horsetrials/times.csv' REPLACE INTO TABLE `springht_data` FIELDS TERMINATED BY ',' LINES TERMINATED BY '\r' IGNORE 1 LINES
    which I can get to run through phpMyAdmin logged in as root. I can also get the SQL command to run through the php script if I connect as ROOT user to localhost..so the problem is with my user mycdcta.

    Code:
    Host localhost - User mycdcta 
    Action	Database 	Table 	Privileges	Grant Option
    Revoke Privileges 	Revoke Grant 	All	All	ALL PRIVILEGES	Yes
    Revoke Privileges 	`mycdcta%`	All	SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER	No
    Revoke Privileges 	`cdcta_com`	All	SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER	No
    Revoke Privileges 	Revoke Grant 	`cdcta\_com`	All	ALL PRIVILEGES	Yes
    I don't have tables "mycdcta%" or "cdcta\_com" but I get errors trying to revoke these lines?

    Code:
    REVOKE SELECT , 
    INSERT ,
    UPDATE ,
    DELETE ,
    CREATE ,
    DROP ,
    INDEX ,
    ALTER ON `` mycdcta % `` . * FROM 'mycdcta'@ 'localhost' 
    
    MySQL said: 
    
    You have an error in your SQL syntax near 'mycdcta%``.* FROM 'mycdcta'@'localhost'' at line 1
    Last edited by Boss Hoss; Jun 26, 2003 at 20:31.

  2. #2
    SitePoint Addict
    Join Date
    Mar 2002
    Posts
    327
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Passwords are case senstive. Is the password Yes or YES?

    Nick
    All4YourPC for all your PC needs. Custom software.
    Websites. Web marketing. Training.
    http://members.aol.com/nickjc67

  3. #3
    SitePoint Zealot
    Join Date
    Jul 2002
    Location
    USA
    Posts
    132
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    uhh..that's just a message saying that a password was expected right?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •