2014-09-20 81 views
0

我正在嘗試爲我的班級處理數據管理項目,但我無法在服務器上導入數據。數據管理-SQL

P.S:我使用的是H2控制檯

CREATE TABLE SERVES AS SELECT * FROM CSVREAD ('C:/Users/H/Downloads/SERVES.csv’); 

錯誤:

CREATE TABLE SERVES AS SELECT * FROM CSVREAD ('C:/Users/H/Downloads/SERVES.csv’);; Syntax error in SQL statement "CREATE TABLE SERVES AS SELECT * FROM CSVREAD ([*]'C:/Users/H/Downloads/SERVES.csv’);"; SQL statement: CREATE TABLE SERVES AS SELECT * FROM CSVREAD ('C:/Users/H/Downloads/SERVES.csv’); [42000-181] 42000/42000 (Help)

+0

您確定這是和MySQL有關的嗎? – Barranka 2014-09-20 04:49:19

+0

'SELECT * FROM CSVREAD('C:/Users/H/Downloads/SERVES.csv');'自己工作嗎? – 2014-09-20 08:01:40

回答

0

您使用了錯誤的那種引號字符來年底字符串文字。您已使用而不是'。因此,而不是:

'C:/Users/H/Downloads/SERVES.csv’ 

使用

'C:/Users/H/Downloads/SERVES.csv' 

的最後一個字符稍有不同。