Siva V

Siva V

  • NA
  • 118
  • 6.5k

Sql Join with multiple columns

Feb 5 2021 9:19 AM
Team,
 
not sure whether here is the right place or not. but need help on this.
 
Country
Id      Name
1      India 
2       UK
3      Canada
4      US 
 
Travel
CountryFrom   CountryTo
1                       2
2                       1 
2                      3
 
 
I need to pull list of countries visited by the user(avoid duplicate countries) and result set should be as follows
Id, CountryVisisted
1     India
2     UK
3     Canada 
 
 Please suggest me

Answers (4)