Applies to: SQL Server 2016 (13.x) and later Azure SQL Database Azure SQL Managed InstanceRename 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....
syntaxsql 複製 -- Syntax for Analytics Platform System (PDW) -- Rename a table RENAME OBJECT [::] [ [ database_name . [ schema_name ] . ] | [ schema_name . ] ] table_name TO new_table_name [;] -- Rename a database RENAME DATABASE [::] database_name TO new_database_...
Using Transact-SQL You can rename a table in SQL Server 2014 by using SQL Server Management Studio or Transact-SQL.Caution Think carefully before you rename a table. If existing queries, views, user-defined functions, stored procedures, or programs refer to that table, the na...
在SQL Server中,RENAME用于重命名数据库对象,如表、列、视图等。它的语法如下:RENAME {object_type::}{old_name old_name} TO new_name其中:- object_type是可选的,表示对象类型,如TABLE、COLUMN、VIEW等。如果不指定object_type,可以通过上下文确定。- old_name是要重命名的对象的旧名称。-old_name是将对象...
Requires ALTER permission on the table. Using SQL Server Management Studio To rename a table In Object Explorer, right-click the table you want to rename and chooseDesignfrom the shortcut menu. From theViewmenu, chooseProperties. In the field for theNamevalue in thePropertieswi...
syntaxsql 複製 sp_rename [ @objname = ] 'object_name' , [ @newname = ] 'new_name' [ , [ @objtype = ] 'OBJECT' ] 引數[ @objname = ] 'object_name'用戶物件或數據類型的目前限定或非限定名稱。 如果要重新命名的對像是數據表中的數據行,object_name必須是 form table.column 或schema...
syntaxsql 複製 sp_rename [ @objname = ] 'object_name' , [ @newname = ] 'new_name' [ , [ @objtype = ] 'OBJECT' ] 引數[ @objname = ] 'object_name'用戶物件或數據類型的目前限定或非限定名稱。 如果要重新命名的對像是數據表中的數據行,object_name必須是 form table.column 或schema...
SQL EXEC sp_rename @objname = 'dbo.table1', @newname = 'table2', @objtype = 'OBJECT'; 相關內容 其他資源 事件 加入我們在 FabCon Vegas 4月1日 上午7時 - 4月3日 上午7時 最終Microsoft Fabric、Power BI、SQL 和 AI 社群主導的活動。 2025 年 3 月 31 日至 4 月 2 日。
如何在SQL Server中重命名表(How to rename a table in SQL Server)Thesp_renameis a stored ...
如何在SQL Server中重命名表 (How to rename a table in SQL Server) The sp_rename is a stored procedure which helps to rename tables in SQL Server and the usage syntax will be like the below: sp_rename是一个存储过程,可帮助重命名SQL Server中的表,用法语法如下所示: sp_rename 'old_table_...