Connecting Tech Pros Worldwide Help | Site Map

Locking a stored procedure!

  #1  
Old June 19th, 2009, 10:15 AM
Member
 
Join Date: Feb 2009
Posts: 54
Hi,

Can i lock a stored procedure in mysql so that others can only be able to view it, but they will not be able to alter it?

Thanks,
Lauren
  #2  
Old June 19th, 2009, 11:49 AM
Atli's Avatar
Moderator
 
Join Date: Nov 2006
Location: Iceland
Posts: 3,701
Provided Answers: 4

re: Locking a stored procedure!


Hi.

You (the database administrator) can decide which privileges each user has.

A user must have the CREATE_ROUTINE privilege to create procedures and the ALTER_ROUTINE privilege to be able to change a procedure.
However, the EXECUTE privilege is all that is required to call a procedure.

So, a user without the first two but with the third would only be able to execute procedures but not alter them.

To grant and revoke privileges, see:
12.5.1.3. GRANT Syntax and 12.5.1.5. REVOKE Syntax.
Reply


Similar Threads
Thread Thread Starter Forum Replies Last Post
stored procedure lock question william.david.anderson@gmail.com answers 5 September 19th, 2007 04:35 PM
Stored procedure and threading help. trialproduct2004@yahoo.com answers 2 November 17th, 2005 11:17 AM
stored procedure debugging in VS.NET Mark answers 2 November 16th, 2005 05:21 PM
Stored procedure deadlock on self with subquery Andrew Mayo answers 7 July 23rd, 2005 09:27 AM
Possible to lock a row within a stored procedure in SQL Server 2000? M Wells answers 12 July 20th, 2005 03:46 AM