|
Hi All,
I am attempting to write a program to
read CSv files from several sub-directories and process them
by adding a date field and part of the file name to the new
file which is again in CSV format.
Directory: c:\
Sub-Dirs : 20010101, 20010102 .................
CSV Files in each directory abc_a.csv, abc_ab.csv abc_se.csv abc_po.csv abc_**** .........
Extract the data from each file merge the date(obtained from the sub-
directory) in date9. format and whatever appears after the _(underscore ) in the
file name .
example
File abc_a in directory 20010101:
1,se,oo,poll
output
1,se,oo,poll,01JAN2001,a
The program should read all the sub-directories in the directory
in this case c:\ and process all files and write them to a separate
location on say another drive or directory in the same csv format .
All assistance is much appreciated as usual.
Sa
|