我想加入两个不同的字段到第三个查找表中的同一个字段。我的数据结构是这样的:MYSQL:加入两个不同的字段到第三个表中的相同的字段
Investments table:
Investment_ID
Company_Country_Code (e.g., US, UK, AU, FR)
Fund_Country_Code (e.g., US, UK, AU, FR)
Country Lookup Table:
Country_Code (e.g., US, UK, AU, FR)
Country_Name (e.g., United States, United Kingdom, Australia, France)
我想加入这两个Company_Country_Code和Fund_Country_Code在全国查找表COUNTRY_CODE表并拉动各Country_Names。我想要这样的数据输出:
(Investment_ID, Company_Country_Name, Fund_Country_Name)
1, United States, France
2, United Kingdom, Australia
3, France, United States
是否有一种特殊的连接来完成此?
谢谢!