DB Technology: MYSQL
Hello Everyone,
Someone knows how to switch to different user without exiting?
Many Thanks !!!
DB Technology: MYSQL
Hello Everyone,
Someone knows how to switch to different user without exiting?
Many Thanks !!!
You cannot do this. However, you can do something a little bit similar.
If you create a view or a stored procedure, you can use SQL SECURITY DEFINER
to allow the person using the view or stored procedure to run statements within that object as if they are the "definer". You can then use the DEFINER=user@host
syntax to specify who that definer is.
See http://dev.mysql.com/doc/refman/5.6/en/stored-programs-security.html for examples of how to do that.