Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 | 31 |
Tags
- early stopping
- merge
- AWS
- sql
- full request
- 버전충돌
- programmers
- hackerrank
- coding
- CSS
- 편향-분산 교환
- mysql
- 깃헙협업
- window function
- github
- elastic net
- conflict
- 클라우드컴퓨팅
- 교차 엔트로피
- PYTHON
- 코딩공부
- 온라인협업
- branch
- Git
- leetcode
- L2정규화
- 선형 모형
- HTML
- RLIKE
- L1정규화
Archives
- Today
- Total
Im between cherry
Leet Code | MySQL | 627. Swap Salary 본문
627. Swap Salary
https://leetcode.com/problems/swap-salary/
Given a table salary, such as the one below, that has m=male and f=female values. Swap all f and m values (i.e., change all f values to m and vice versa) with a single update statement and no intermediate temp table.
Note that you must write a single update statement, DO NOT write any select statement for this problem.
After running your update statement, the above salary table should have the following rows:
UPDATE salary
SET sex = CASE
WHEN sex = 'f' THEN 'm'
ELSE 'f'
END
'데이터분석 > practice_query' 카테고리의 다른 글
Leet Code | MySQL | 180. Consecutive Numbers (0) | 2020.08.30 |
---|---|
Leet Code | MySQL | 196. Delete Duplicate Emails (0) | 2020.08.30 |
Leet Code | MySQL | 181. Employees Earning More Than Their Managers (0) | 2020.08.30 |
Hackerrank | MySQL | The Report (0) | 2020.08.30 |
Hackerrank | MySQL | Challenges (0) | 2020.08.29 |
Comments