The system stored procedure sp_dboption is not available in SQL Server 2012 anymore. How could it be replaced?


sp_dboption was deprecated a while ago - http://msdn.microsoft.com/en-us/library/ms187310(v=sql.105).aspx

The recommended alternative is ALTER DATABASE - http://msdn.microsoft.com/en-us/library/ms174269.aspx

| improve this answer | |
  • 1
    What's the replacement for getting options? Just query sys.databases? – Rory Dec 17 '13 at 14:43

This is probably extremely terrible advice but I'll post it anyways: I needed to create a SharePoint 2003 (WSS 2.0) site and I am using SQL Server 2014 for my DB Server. I could not create a site collection. I copied the contents of the sys.sp_dboption stored procedure and created it in my master database on SQL Server 2014 (in the dbo namespace) and SharePoint works now.

So yeah, that can be an option if you're stuck...

| improve this answer | |
  • Told you it was terrible advice :) – CMerat Mar 2 '15 at 22:43
  • Maybe terrible advice, but it got me out of a pickle. Thanks for daring to post it! – JV. Mar 13 '15 at 15:39
  • Nice. Got me out of a pickle with an old version of Fortress too. – Program.X Oct 8 '15 at 13:28
  • Terrible, but for test database it was very useful! Thank You :) – Gennady G Dec 18 '16 at 15:39
  • Ran into this issue while recovering a WSS farm to upgrade to current. This was also helpful in providing the required sp for the installer. sp_ms_marksystemobject – George Jul 26 '18 at 12:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.