I have a CSV with invoice data - e.g.:
- Invoice #
- PO Ref
- Customer Code
- Customer Name
- Document Date
- Product Code
- Product Name
This CSV will have varying amounts of lines per invoice, which relate to invoice produt lines, which may span multiple invoice numbers.
I need to be able to run a batch file to look at this CSV and split off into multiple CSVs based on the value in Col A - Invoice #.
Eg:
- 111222,PO123,C100000,Test Store,1/1/15,AB1000,Test Soft Toy
- 111222,PO123,C100000,Test Store,1/1/15,AB1001,Test Soft Toy1
- 111222,PO123,C100000,Test Store,1/1/15,AB1002,Test Soft Toy2
- 222111,PO321,C111000,My Store,1/10/15,AB1000,Test Soft Toy
- 222111,PO321,C111000,My Store,1/10/15,AB1001,Test Soft Toy1
- 222111,PO321,C111000,My Store,1/10/15,AB1002,Test Soft Toy2
The .bat should run and split the CSV into 2 separate CSV's:
CSV1:
- 111222,PO123,C100000,Test Store,1/1/15,AB1000,Test Soft Toy
- 111222,PO123,C100000,Test Store,1/1/15,AB1001,Test Soft Toy1
- 111222,PO123,C100000,Test Store,1/1/15,AB1002,Test Soft Toy2
CSV2:
- 222111,PO321,C111000,My Store,1/10/15,AB1000,Test Soft Toy
- 222111,PO321,C111000,My Store,1/10/15,AB1001,Test Soft Toy1
- 222111,PO321,C111000,My Store,1/10/15,AB1002,Test Soft Toy2
Getting software installed on my server is going to a hassle - as such, if there is anyway that this can be done without having to install software this would make me very happy.
I appreciate that there have been similar questions asked previously - however, I haven't been able to find out if there is another script I can run without installing Awk.
Regards Rick