Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
不确定此语句中错误指的是什么语法:-
Use MyDatabase CREATE TABLE TestTable AS (SELECT * FROM dbo.MyTable);
任何帮助表示赞赏!
这dbo表明您正在使用 SQL Server。语法错误是不支持此语法。
dbo
SQL Server 中的等效语法是:
SELECT * INTO TestTable FROM dbo.MyTable;
你需要像下面这样使用。您正在使用的是 Oracle 语法。
Use MyDatabase Go SELECT * INTO TestTable FROM dbo.MyTable GO