MySQL 7

SQL/MySQL의 기초 - WHERE, SubQuery

https://leetcode.com/problems/second-highest-salary/ Second Highest Salary - LeetCode Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview. leetcode.com 문제를 해석 하자면 두 번째로 높은 임금을 구하여라. 그러나 두 번째 높은 값이 없을 경우에는 null을 출력하라라는 뜻입니다. 그러나 문제를 풀 것은 아니고, 이 문제로 WHERE과 SubQuery를 배워봅시다. 일단 아래의 코드가 위에 링크 문제의 답입니다. SELECT MAX..

[MySQL] 3. 175. Combine Two Tables [LeetCode Easy]

https://leetcode.com/problems/combine-two-tables/ 해석: Write an SQL query to report the first name, last name, city, and state of each person in the Person table. If the address of a personId is not present in the Address table, report null instead. cs firstName , lastName, city, state를 출력하라, 그러나 Address table에 personId가 없으면, null을 리턴하라는 내용입니다. Person table과 Address table이 나오며 Null이 나오니, 두 테이블을 합..

Leetcode 2022.05.25