ALTER SCHEMA

Posted by: SQL Server DBA, on 24 Oct 2011 | View original | Bookmarked: 0 time(s)

Use this select statement to create a list of ALTER SCHEMA statements for all stored procedures in a SQL Server 2005 database. dbo  can be changed to whatever schema name required USE myDb GO SELECT 'ALTER SCHEMA dbo TRANSFER ' + s.Name + '.' + p.Name FROM sys.Procedures p INNER JOIN sys.Schemas s on p.schema_id = s.schema_id WHERE s.Name = 'mySchema' order by p.Name   Use this select statement to create a list of ALTER SCHEMA statements for all tables and views in a SQL Server 2005...

Advertisement
Free Agile Project Management Tool from Telerik
TeamPulse Community Edition helps your team effectively capture requirements, manage project plans, assign and track work, and most importantly, be continually connected with each other.
Category: XSD | Other Posts: View all posts by this blogger | Report as irrelevant | View bloggers stats | Views: 252 | Hits: 6

Similar Posts

  • Migrating data from one database server to another with Telerik OpenAccess ORM more
  • Bulletproof Database Synchronization with dbForge Schema Compare for SQL Server 1.50 more
  • SQL SERVER Importance of Database Schemas in SQL Server more
  • LLBLGen Pro and SQL Azure more
  • Some MVC Implementing more
  • Ruminations on Multi-Tenant Data Architectures more
  • Next version of EF Code Only Design laid out by MS more
  • SQL SERVER Two Methods to Retrieve List of Primary Keys and Foreign Keys of Database more
  • The usual result of Poor Mans Dependency Injection more
  • New Feature: Artificial Fields more

News Categories

.NET | Agile | Ajax | Architecture | ASP.NET | BizTalk | C# | Certification | Data | DataGrid | DataSet | Debugger | DotNetNuke | Events | GridView | IIS | Indigo | JavaScript | Mobile | Mono | Patterns and Practices | Performance | Podcast | Refactor | Regex | Security | Sharepoint | Silverlight | Smart Client Applications | Software | SQL | VB.NET | Visual Studio | W3 | WCF | WinFx | WPF | WSE | XAML | XLinq | XML | XSD