|
Help Needed : Split one big file to multiple files
Hi friends,
I have data in flat file as following, first filed is the customer number. We have almost 50-100 customers in the system
100 ABC A123
100 BVC D234
100 BNC N324
200 CBC A122
200 AVC D294
200 HNC N324
300 GBC A173
300 FVC D234
300 DNC N344
I want to split the file and create individual file for each customer with customer number in the file name as follows,
File Name : 100.<TimeStamp>.txt
100 ABC A123
100 BVC D234
100 BNC N324
File Name : 200.<TimeStamp>.txt
200 CBC A122
200 AVC D294
200 HNC N324
File Name : 300.<TimeStamp>.txt
300 GBC A173
300 FVC D234
300 DNC N344
I really apprciate if anyone can help me writing this script.
|