Query the Western Longitude (LONG_W) for the largest Northern Latitude (LAT_N) in STATION that is less than 137.2345 . Round your answer to 4 decimal places.
Input Format
The STATION table is described as follows:
where LAT_N is the northern latitude and LONG_W is the western longitude.
- query LONG_W ==> SELECT LONG_W
- round answer to 4 decimal places ==> SELECT ROUND(LONG_W, 4)
- in STATION table ==> FROM STATION
- LAT_N less than 137.2345 ==> WHERE LAT_N < 137.2345
- for the largest LAT_N ==> ORDER BY LAT_N DESC LIMIT 1
SELECT ROUND(LONG_W,4)
FROM STATION
WHERE LAT_N < 137.2345
ORDER BY LAT_N DESC LIMIT 1;
'Algorithm > SQL' 카테고리의 다른 글
[SQL][HackerRank] The Report (0) | 2020.06.12 |
---|---|
[SQL][HackerRank] Weather Observation Station 16 (0) | 2020.06.12 |
[SQL][HackerRank] Weather Observation Station 14 (0) | 2020.06.12 |
[SQL][HackerRank] Weather Observation Station 13 (0) | 2020.06.12 |
[SQL][HackerRank] Weather Observation Station 2 (0) | 2020.06.12 |