An exception occurred while executing a transact-sql statement or batch

krishna picture krishna · Dec 28, 2016 · Viewed 65.8k times · Source

I keep getting the error message:

an exception occurred while executing a transact-sql statement or batch

when trying to do anything in SQL Server Management Studio 2016.

This occurs when I try to create or edit a login, when I try to create a new database, basically when I do anything.

I tried the solution given in SQL Server 2008 R2 Express permissions -- cannot create database or modify users but I can't edit the Startup Parameters specified in step 6.

Can anyone explain what the issue is and how to solve it?

Answer

krishna picture krishna · Dec 29, 2016

Thanks to everyone who tried to answer the question, but I was able to solve it. It is the same procedure mentioned in SQL Server 2008 R2 Express permissions -- cannot create database or modify users. However, in step 6 instead of adding "-m" to an existing parameter, you have to create a new parameter called "-m" and follow the remaining steps. This resolved the issue.