【SQLSERVER】获取建表DDL(+主键)

--获取建表DDL(+主键) declare @tabname varchar(50) set @tabname='testbzm'--表名 if ( object_id('tempdb.dbo.#t') is not null) begin DROP TABLE #t end select 'create table [' + so.name + '] (' + o.list + ')' + C
相关文章
相关标签/搜索