Hello,
I am new to python and I work on excel everyday which is more of manual. I need to automate some part using python as I am interested in learning it. I need python gurus to help me in coding.
I have data in excel 1 which I need to read and then go to excel 2 find them in excel 2 and get the values in columns.
Below is the example data I have and rules on how to populate data
- Read row 1 & column 1 from excel 1, go to excel 2 find AAAAAA and get value from column A and write to column 2 row 1 in excel 1
- Always skip middle row if column 1 in excel 1 has more than two entries
- Read row 3 & column 1 from excel 1, go to excel 2 find AAAAAA and get value from column B and write to column 2 row 3 in excel 1
Excel 1 Excel 2
row column 1 column 2 column X column A column B
1 AAAAAA CCCCCC 20 30
2 AAAAAA AAAAAA 40 50
3 AAAAAA BBBBBB 10 30
4 BBBBBB
5 BBBBBB
6 CCCCCC
7 CCCCCC
8 CCCCCC
Result should be like below
Excel 1
row column 1 column2
1 AAAAAA 40
2 AAAAAA
3 AAAAAA 50
4 BBBBBB 10
5 BBBBBB 30
6 CCCCCC 20
7 CCCCCC
8 CCCCCC 30
Please anyone help me on this