MySQL, PHPMyAdmin, GRANT, headaches

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm setting up a site and am having loads of problems with MySQL (which i don't use much, being a Postgres fan). The server is not controlled by myself and I'm waiting on a reply from the admin. In the meantime:

PHP 4.3.9
Mysql 4.1.10a (server) 3.23.49 (client)

The database has been set up along with PHPMyAdmin (i also rarely use this). I have been provided with a user & pass for PHPMyAdmin, as well as a user & pass for the DB. Using the former, i have created the tables and copied in my data. Within that interface, i can make any query i'd like.

However, from within a PHP script (and using the second user & pass), i seem to be SOL. Even the most basic queries return empty results. Debugging has been a royal pain because interfaces such as MDB2, DB, etc. are also not available. That means relying on mysql_error() which is frustrating.

After much dicking around, i've come to the conclusion that the problem must be that the user does not have permission to select from the DB. A comment on the mysql_error() manual page [1] says that, in the case of "Access denied ..." mysql_error() returns the empty string.

I feel like i've taken crazy pills! Please, someone tell me this isn't true! How does one debug a problem like this? How can i know if i have SELECT rights to the table?

[1] http://ca3.php.net/manual/en/function.mysql-error.php#44168

brian

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux