我正在尝试将CSV导入到SQL中。 CSV是非常大的4克,所以这真的是查询数据的唯一选择,我相信。CREATE TABLE给出错误4145和102
我已经到了创建新数据库的地步,现在正在尝试创建将保存信息的表。
我已经运行以下命令:
CREATE TABLE Provider_NPI
(NPI INT,
Entity Type Code INT,
Replacement NPI INT,
Employer Identification Number (EIN) INT,
的INT后,它继续了超过300个加标题,但有一个`味精4145,级别15,状态1,行上三个不同的人错误X'错误。我列出了出来
Error:
Msg 102, Level 15, State 1, Line 5
Incorrect syntax near 'Code'.
对于此行:Replacement NPI INT,
高于此线是Entity Type Code INT,
Error:
Msg 4145, Level 15, State 1, Line 29
An expression of non-boolean type specified in a context where a condition is expected, near 'U'.
这条线:Provider Business Mailing Address Telephone Number VARCHAR(75),
Error:
Provider Business Practice Location Address Telephone Number VARCHAR(75),
此行:Provider Business Practice Location Address Telephone Number VARCHAR(75),
任何人都可以帮我确定什么是错的?我相信这可能与一些标题名称有关?
你被允许在这样的列名中有空格吗?在这种情况下,标识符周围是否需要括号? – bernie 2013-02-14 20:58:00
我是一个SQL的总noob,所以我猜你的意思是.. [实体类型代码] INT, – jjones312 2013-02-14 21:04:05
是的,这正是我的意思。 – bernie 2013-02-14 21:06:48