That syntax only works in 4.1.2 and up, however. Prior versions only take a
string for the user, not a function call or variable. In that case, you can
find out who you are with
SELECT CURRENT_USER();
+-----------------+
| CURRENT_USER() |
+-----------------+
| [EMAIL PROTECTED] |
+-----------------+
1 row in set (0.00 sec)
Then check the privileges with
SHOW GRANTS FOR [EMAIL PROTECTED]
See the manual for more <http://dev.mysql.com/doc/mysql/en/SHOW_GRANTS.html>.
Michael
Gleb Paharenko wrote:
Hello.
SHOW GRANTS FOR CURRENT_USER();
Law Poop <[EMAIL PROTECTED]> wrote:
Can a user see their own permissions for a database?
I'm working on a PHP project that will hopefully automagically
generate forms based on a user's permissions. Do I have to create a
seperate account to find out what a particular user's permissions are,
or is there some way to read permissions with a user's own
credentials?
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]