hello
I have about five files in the same folder contain data and I have file name's target , the file TARGET contain data from col A:H what I want match COL B,C,D with the five files also the columns B,C,D and brings the values based on topic headers to FILE TARGET after last column is filled in H the headers IM1,EX1,RT1,SA1,PU1 are different in location in five files
this is the simple data but my real data are at least 5000 rows
first when target file before bring the values
and expected result
I have about five files in the same folder contain data and I have file name's target , the file TARGET contain data from col A:H what I want match COL B,C,D with the five files also the columns B,C,D and brings the values based on topic headers to FILE TARGET after last column is filled in H the headers IM1,EX1,RT1,SA1,PU1 are different in location in five files
this is the simple data but my real data are at least 5000 rows
first when target file before bring the values
ITEM | GOODS | TYPE | PR | EX | RT | SA | PU | IM1 | EX1 | RT1 | SA1 | PU1 |
1 | FRIUT | BANANA | SO | 200 | 123 | 45 | 12 | |||||
2 | VEGETIBLE | TOMATO | EG | 100 | 100 | 100 | 100 | |||||
3 | FOOD1 | TUNE160G | SP | 150 | 150 | 150 | 200 | |||||
4 | FOOD2 | TUNE180G | TH | 250 | 123 | 250 | 14 | |||||
5 | FOOD3 | CHEESE CHEEDER | NE | 300 | 300 | 78 | 12 | |||||
6 | FRIUT | APPLE | TU | 120 | 56 | 120 | 58 | |||||
7 | VEGETIBLE | POTATO | GR | 100 | 100 | 100 | 65 | |||||
9 | FOOD5 | BISCUITS SW | SW | 150 | 150 | 58 | 47 | |||||
10 | FOOD1 | TUNE160G | IN | 140 | 140 | 140 | 88 | |||||
11 | FOOD2 | TUNE180G | TW | 130 | 88 | 77 | 99 | |||||
12 | FOOD3 | CHEESE MOZZIRELA | IT | 300 | 300 | 44 | 66 | |||||
13 | FOOD5 | BISCUITS SW | SS | 250 | 45 | 250 | 250 | |||||
14 | FRIUT | APPLE | IT | 120 | 99 | 120 | 120 | |||||
15 | VEGETIBLE | ONION | PO | 100 | 100 | 12 | 100 | |||||
16 | VEGETIBLE | ONION | LOC | 101 | 101 | 101 | 101 | |||||
and expected result
ITEM | GOODS | TYPE | PR | EX | RT | SA | PU | IM1 | EX1 | RT1 | SA1 | PU1 |
1 | FRIUT | BANANA | SO | 200 | 123 | 45 | 12 | 445 | ||||
2 | VEGETIBLE | TOMATO | EG | 100 | 100 | 100 | 100 | 467 | 679 | 33 | ||
3 | FOOD1 | TUNE160G | SP | 150 | 150 | 150 | 200 | 234 | ||||
4 | FOOD2 | TUNE180G | TH | 250 | 123 | 250 | 14 | |||||
5 | FOOD3 | CHEESE CHEEDER | NE | 300 | 300 | 78 | 12 | 7844 | ||||
6 | FRIUT | APPLE | TU | 120 | 56 | 120 | 58 | 33 | ||||
7 | VEGETIBLE | POTATO | GR | 100 | 100 | 100 | 65 | 33 | 33 | |||
9 | FOOD5 | BISCUITS SW | SW | 150 | 150 | 58 | 47 | 33 | ||||
10 | FOOD1 | TUNE160G | IN | 140 | 140 | 140 | 88 | |||||
11 | FOOD2 | TUNE180G | TW | 130 | 88 | 77 | 99 | 3 | ||||
12 | FOOD3 | CHEESE MOZZIRELA | IT | 300 | 300 | 44 | 66 | 33 | ||||
13 | FOOD5 | BISCUITS SW | SS | 250 | 45 | 250 | 250 | 33 | 333 | 33 | ||
14 | FRIUT | APPLE | IT | 120 | 99 | 120 | 120 | |||||
15 | VEGETIBLE | ONION | PO | 100 | 100 | 12 | 100 | 3 | ||||
16 | VEGETIBLE | ONION | LOC | 101 | 101 | 101 | 101 | 33 | ||||