ASPNetFAQ.com: What is ASP.NET?

Technology posts on ASP.NET, IIS, Windows (+ a little Linux), Cloud Servers, Hosting, and more!
  • Blog Home
Search the site...

Changing the table owner in SQL Server 2012

Tweet
Share
0 Shares

When OrcsWeb says they do Managed Windows Server Hosting, they really mean it. As part of that managed hosting, they often engage in beta programs and include their clients so that both the OrcsWeb staff and the end-users can get familiar with certain products prior to the release. One such product is Microsoft SQL Server 2012 (aka Denali), and an example of the type of troubleshooting and assistance provided is reflected below…

We ran into a situation today where we needed to change the owner of a table in Microsoft SQL Server 2012 RC0. In SQL Server 2008 R2 we would use the command:

sp_changeobjectowner ‘[BadUser].[NameOfTheTable]’, ‘dbo’

But when attempting that on SQL2012 it wouldn’t work. It was claiming that either the object didn’t exist or the command wasn’t valid for that object type.




I’m not sure if that is a bug or if they changed the functionality of that SPROC on purpose.

We were able to find a workaround though by changing the schema information with the following command:

alter schema dbo transfer [BadUser].[NameOfTheTable]

If someone knows why the first SPROC didn’t work and the second had to be used, please let the rest of us know by posting in the comments.

UPDATE: Looks like this is by design:
http://technet.microsoft.com/en-us/library/ms143729(v=sql.110).aspx

That’s one of many functions depreciated in 2012 (and future versions).

Happy hosting!

More from my site

  • Implementing Application Initialization on IIS 7.5Implementing Application Initialization on IIS 7.5
  • SQL Server restore failure and resolutionSQL Server restore failure and resolution
  • Orchard: Custom Content in Sub-FoldersOrchard: Custom Content in Sub-Folders
  • Resolving a “There is a duplicate ‘system.web.extensions/scripting/scriptResourceHandler’ section defined” ErrorResolving a “There is a duplicate ‘system.web.extensions/scripting/scriptResourceHandler’ section defined” Error
  • IIS7 Application Pool Idle Time-out SettingsIIS7 Application Pool Idle Time-out Settings
Tweet
Share
0 Shares
Hosting, SQL/Databases, System Administration, tip, Troubleshooting

Comments are closed.

Proverbs 19:20

"Get all the advice and instruction you can, so you will be wise the rest of your life."

A Note On WordPress Hosting

Our main focus is of course .NET, but with a mix of Linux, virtualization, and other technologies. But if you're really looking for the best WordPress hosting specifically, read my WordPress host review to save yourself hassle AND money!




Recent Posts

  • What makes good web hosting?
  • jQuery Mobile C# ASP.NET and N5 Networks Software Repository
  • Open Source Bug Tracking Software and the Orchard Project
  • ASP.NET Development with Dreamweaver MX: Visual QuickPro Guide
  • Kendo UI Sample, ASP.NET Ajax Tutorial & More

Tags

ASP.NET Automation centos CMS css cytanium Development/Coding Email gmail Hosting htaccess http https IIS javascript Learning Linux logparser MySQL nginx openssl OrcsWeb performance PowerShell redirect RHEL security server SherWeb smtp SQL/Databases ssl System Administration telnet terminal tip Troubleshooting Ubuntu virtualization Visual Studio web farm web hosting Windows windows server Wordpress

Categories

  • ASP.net development
  • Development/Coding
  • Hosting
  • IIS (Internet Information Services)
  • SQL/Databases
  • System Administration
  • Virtualization
(c) ASPNETFAQ.com