Advertisement
dragonbs

Highest Peaks in Bulgaria

Sep 28th, 2023
1,025
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
T-SQL 0.34 KB | None | 0 0
  1. SELECT
  2.     c.[CountryCode],
  3.     m.[MountainRange],
  4.     p.[PeakName],
  5.     p.[Elevation]
  6. FROM [Countries] c
  7. JOIN [MountainsCountries] mc ON c.[CountryCode] = mc.[CountryCode]
  8. JOIN [Mountains] m ON mc.[MountainId] = m.[Id]
  9. JOIN [Peaks] p ON m.[Id] = p.[MountainId]
  10. WHERE p.[Elevation] > 2835 AND c.[CountryName] = 'Bulgaria'
  11. ORDER BY p.[Elevation] DESC
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement