[HackerRank|MySQL] Revising the Select Query I - II

히끼·2020년 8월 21일
0

HackerRank

목록 보기
3/13

Revising the Select Query I

Problem

Query all columns for all American cities in the CITY table with populations larger than 100000. The CountryCode for America is USA.

Solution

SELECT *
FROM CITY
WHERE COUNTRYCODE = 'USA' AND POPULATION > 100000

Revising the Select Query II

Problem

Query the NAME field for all American cities in the CITY table with populations larger than 120000. The CountryCode for America is USA.

Solution

SELECT NAME
FROM CITY
WHERE COUNTRYCODE = 'USA' AND POPULATION > 120000

0개의 댓글