Mysql load data infile 命令格式

【1】Linux系統環境下spa

LOAD DATA INFILE /usr/LOCAL/lib/ubcsrvd/datacsv/201909_source.csv INTO TABLE np_cdr_201909 FIELDS TERMINATED BY ',' IGNORE 1 LINES (product_id, calling_id, start_time, duration, call_type, @fee) SET original_fee = @fee * 1000, insert_time = SYSDATE(), np_id = 'abdefg', cdr_state = '00', source = 'kaizenly';

【2】Windows系統環境下code

LOAD DATA INFILE 'C:/Users/Administrator/Desktop/201909/201909_source.csv' 
INTO TABLE np_cdr_201909 FIELDS TERMINATED BY ',' IGNORE 1 LINES (product_id, calling_id, start_time, duration, call_type, @fee) SET original_fee = @fee * 1000, insert_time = SYSDATE(), np_id = 'abdefg', cdr_state = '00', source = 'kaizenly';

 

Good Good Study, Day Day Up.blog

順序 選擇 循環 總結io

相關文章
相關標籤/搜索