Plinio,
Hence my suggestion for use of a flat file. The file can be located on the
db server middle tier wherever it doesnt matter.
The important part is that you control what goes in the file and its done
ahead of time not when an enduser presses a button.
What about creating tables the users can view loaded with the system table
information your users need to see(same as flat file just do it with table
in the database).
It would be much better if you could get the information together and then
let endusers view it as opposed
to firing two statements and going through a bunch of parsing etc ... like
you stated below everytime they press a button.
The route your taking will be slower,more resource intensive and more
complicated.




----- Original Message ----- 
From: "Plinio Conti" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, December 23, 2003 11:58 AM
Subject: Re: Quering user privileges


> To be honest, the fact I can't get it with only one query but I have to
do:
>
> 1) SELECT CURRENT_USER();
>
> 2) SHOW GRANTS FOR valueExtractedByPreviousQuery;
>
> is a little thing compared with work remaing to get usefull information:
> I have to parse the strings returned by query 2, handle the wildcards,
handle "ALL PRIVILEGES", comparing db-level privileges with table-level ones
and with column-level ones, etc...
>
> I probably will do all that, only I wonder there is not a more simple
solution.
>
> I mean, it looks a so common issue that I imagine there is better solution
but I can't figure which.
>
> User authenticates, and client app wants to know what that user is allowed
to do, so the app can show to its user the correct user interface (for
example editing disabled if user can't write, etc..)
>
>
>
>
> -- 
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]
>


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to