Sql-server – Can you edit the context menu options

sql serverssms

Is there a way (registry hack is acceptable) to remove options from the context menus in SSMS?

Specifically I'd like to remove the delete option from the context menu when you right click on a merge replication publication. If we really want it deleted we'll do it via tsql.

And yes, there is a tragic tale motivating this question.

Best Answer

I suspect the "tragic tale" might be that someone who had sysadmin privileges (but shouldn't have) went in and deleted one of these things (possibly by mistake).

But another thought occurred to me: someone who should have sysadmin privileges might have done the same thing (by mistake).

In lieu of being able to cripple Management Studio (which I suppose you could do by writing your own an add-in), you should consider simply not logging in as sysadmin except when absolutely necessary.

At my old job we tried to implement a policy where by default you connect to SQL Server as you, and you are given the rights you should have for most tasks. When you need to escalate to do something out of the ordinary, only then do you connect as sysadmin. This worked with some success - however you need to be tolerant of the moaning and griping that will happen. We actually had different database roles such as a read only for our QA department - allowing them, say, to validate a report output by selecting from certain tables directly.