I have a requirement as below,
Am calling sqlldr script via shell for the CSV files present in a folder, File name also has Timestamp attached with it.
I need to insert that timestamp into a column of table. Kindly suggest me how i can achieve this.
eg:
table:
t1(c1 varchar,c2 varchar,c3 timestamp);
control file :
load data
infile 'file.csv'
append
into table t1
fields terminated by "|" TRAILING NULLCOLS
( c1, c2)
csv_file : cat file_csv_101010112233.csv
1111|1
2222|2
OUTPUT :
select * from t1;
c1 c2 c3
1111 1 101010112233
2222 2 101010112233
Note : I dont want the sys timestamp
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…