This article describes how to rename a user-defined database in SQL Server, Azure SQL Database, or Azure SQL Managed Instance, by using SQL Server Management Studio (SSMS) or Transact-SQL (T-SQL). The name of th
2. In SQL Server In SQL Server, we can use the ALTER DATABASE statement to rename a database: ALTER DATABASE [OldDatabaseName] MODIFY NAME = [NewDatabaseName]; We replace [OldDatabaseName] and [NewDatabaseName] with old and new database names. Before renaming, we must ensure there...
SQL Server Docs navigation tips Previous versions 2005-2014 Business continuity Database design Development Internals & Architecture Installation Migrate & load data Manage, monitor, & tune Query data Reporting & Analytics Security Tools Tutorials
Option 2 - Rename SQL Database using SSMS If you are using SQL Server Management Studio, right click on the database name and select the option "Rename". This did not exist in SQL Server 2000, but if you use Management Studio to manage SQL Server 2000 you can also take advantage of t...
Rename a table in SQL Server, Azure SQL Managed Instance, or Azure SQL Database.To rename a table in Azure Synapse Analytics or Parallel Data Warehouse, use RENAME OBJECT.გაფრთხილება Think carefully before you rename a table. If existing queries, views, user-...
適用対象 SQL Server (サポートされているすべてのバージョン) と Azure SQL Database: sp_rename は、PRIMARY KEY 制約または UNIQUE 制約の名前が変更されるたびに、関連付けられているインデックスの名前を自動的に変更します。 名前が変更されたインデックスが PRIMARY KEY 制約に関連付けら...
Using SQL Server Management Studio Using Transact-SQL Applies to: SQL Server Azure SQL Database Azure SQL Managed Instance SQL database in Microsoft Fabric This topic describes how to rename an index in SQL Server by using SQL Server Management Studio or Transact-SQL. Renaming an index replace...
STATISTICS 適用於:SQL Server 2012 (11.x) 和更新版本,以及 Azure SQL Database。用戶明確建立或以索引隱含建立的統計數據。 重新命名索引的統計數據也會自動重新命名索引。 USERDATATYPE 執行CREATE TYPE 或 sp_addtype所新增的 CLR 使用者定義型別。 適用於:Azure Synapse Analytics 在sp_rename Azure Synapse ...
STATISTICS適用於:SQL Server 2012 (11.x) 和更新版本,以及 Azure SQL Database。 用戶明確建立或以索引隱含建立的統計數據。 重新命名索引的統計數據也會自動重新命名索引。 USERDATATYPE執行CREATE TYPE 或sp_addtype所新增的 CLR 使用者定義型別。 適用於:Azure Synapse Analytics ...
Syntax forsp_renamein SQL Server and Azure SQL Database: syntaxsql sp_rename[ @objname = ]'object_name', [ @newname = ]'new_name'[ , [ @objtype = ]'object_type'] Syntax forsp_rename(preview) in Azure Synapse Analytics: