我是PostgresSQL的新手,我正尝试加载以下格式的数据:
1,57000000000A,A,EN,0:01,male,hahaha,"Address is address",1234567,Not Applicable,, walk in and scream,papa,00:20:54,02:17:41,ABC,00:20:54,02:17:41,musical,farm,,cody,9,bad boy,,,,,X,,rest,,,musical is muscal,John Kotters ,,,2011-01-01
记录超过1万,某些列可能包含NULL数据。当我尝试这样做时:
COPY ane FROM 'C:/Program Files (x86)/PostgreSQL/8.4/csv-data/my-data.csv' WITH DELIMITER ',';
我收到以下错误:ERROR:最后一个预期的列SQL状态之后的多余数据:22P04
我已经检查了列,它们还可以。这意味着不会遗漏任何列。
希望有人能帮忙。提前谢谢。
应该是
COPY ane FROM 'C:/Program Files (x86)/PostgreSQL/8.4/csv-data/my-data.csv' WITH DELIMITER ',' CSV;
对我有用