Dear all,
I have two excel sheets with hundreds of rows that I would like to merge. (see example below).
I would like to add the value column to the first table based on Year and Country. However when I use the Join tool I get hundreds of more rows in my data. Could you please tell me what I am doing wrong.
In the first one I have data on companies
Company | Year | Country |
1 | 2015 | Canada |
2 | 2016 | USA |
3 | 2017 | UK |
In the second one I have data on countries:
Country | Year | Value |
Canada | 2015 | 1 |
USA | 2016 | 2 |
UK | 2017 | 3 |
Solved! Go to Solution.
Hi @auser537
Join key combination should be unique either in one of the data sources. If not it causes one to many or many to many joins. In your scenario, you can probably use unique tool on 2nd data source select columns country and year like below. Considering for every year every country has only one value.
Hope this helps : )