我对SQLite3数据库的查询有问题
查询是这样的:
CREATE TABLE new_test AS (SELECT column1,column2 FROM test1)
或者这个:
CREATE TABLE 'new_test' AS (SELECT 'column1','column2' FROM test1)
错误是这样的:
near "(": syntax error
答案 0 :(得分:1)
如the documentation所示,SELECT语句周围没有括号:
CREATE TABLE new_test AS SELECT column1, column2 FROM test1