How to dymanically skip columns while loading
918103Mar 14 2012 — edited Mar 14 2012datafile
cust grade age description
AAA,A,25,Vic
BBB,A,34,Man
CCC,A,23,Dir
DDD,A,25,SM
EEE,A,29,DBM
fields in table 1
cust, age, description
fields in table 2
cust, grade, age
control file to load data in table 1
options (skip=(1) direct=true)
load data
infile 'c:\data.csv'
replace
into table tab_abc
fields terminated by ','
TRAILING NULLCOLS
(
cust,
surame FILLER,
age,
description
)
not sure if FILLER is something i can use here.
Any help is really appreciated. Let me know if more information is needed.