我的数据是这样的:
ID,SCORE_DATE,TYPE,SCORE,RAW_SCORE,RANK
A1234,2012-09-05 23:59:59,FOOTBALL_TEAM_MIDDLE_AND_OLD_1234,10,0.123,1
A5678,2012-09-05 23:59:59,FOOTBALL_TEAM_MIDDLE_AND_OLD_1234,20,0.456,2
CTL 文件:
load data
infile 'E:\Data\Sample.csv'
badfile 'E:\Data\Sample.bad'
APPEND into table TABLE1
fields terminated by "," optionally enclosed by '"'
TRAILING NULLCOLS
(
DRIVER,
STARTDTE "to_date(SUBSTR(:STARTDTE,1,10),'YYYY-MM-DD') - 27",
TYPE CONSTANT 'FOOTBALL',
SCORE ,
RANKSCORE ":SCORE",
RANK ,
ENDDTE "to_date(SUBSTR(:STARTDTE,1,10),'YYYY-MM-DD')",
LOADDT "sysdate"
)
这是我的表结构:
CREATE TABLE "TABLE1"
(
"DRIVER" VARCHAR2(50 BYTE),
"STARTDTE" DATE,
"SCORE" NUMBER,
"ENDDTE" DATE,
"TYPE" VARCHAR2(20 BYTE),
"RANK" NUMBER,
"RANKSCORE" NUMBER,
"LOADDT" VARCHAR2(20 BYTE)
);
对于加载的每一行,我都会收到一条错误消息:记录 3:拒绝 - 表 TABLE1 列 SCORE 上的错误。ORA-01722: 无效号码
怎么了?