Dear Community,
Aiming to calculate share of investors types (based on all active and former investors) for each company. As a first step for this, I would like to merge the two tables below.
Table A: Companies with investor names
| Company name | Active investor name | Former investor name |
| Company1 | Investor1,Investor5 | Investor100,Investor2 |
| Company2 | Investor1, Investor2...Investor20 | Investor1, Investor2...Investor20 |
| .... | | |
| Company5000 | Investor51 | Investor3 |
Table B: Investors with investor types
| Investor name | Investor type |
| Investor1 | Venture Capital |
| Investor2 | Private Equity |
| .... | ... |
| Investor1000 | State |
The manual way would be to 1) Split text within "active investor name" and "former investor name" columns to several columns by , 2) Join each column via investor name from the second table. But this way I have to perform tons of joins separately as I will end up with hundreds of new columns that need to be joined with second table to get "investor type" - so I was hoping there might be an easier way?
Output table should look like this. If you think there is an easier way to calculate the share of investor types per company, I'm also open to alternative approaches!
| Company name | Active investor name 1 | Active investor name 1_type | Active investor name 2 | Active investor name 2_type | Former investor name 1 | Former investor name 1_type | Former investor name 2 | Former investor name 2_type |
| Company1 | Investor1 | Venture Capital | Investor5 | xxx | Investor100 | xxx | Investor2 | Private Equity |
Many thanks in advance!