Skip to content

Commit befb83e

Browse files
committed
[level 3] Title: 자동차 대여 기록에서 대여중 / 대여 가능 여부 구분하기, Time: , Memory: undefined -BaekjoonHub
1 parent 2d9fafc commit befb83e

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

프로그래머스/3/157340. 자동차 대여 기록에서 대여중 / 대여 가능 여부 구분하기/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,19 @@
44

55
### 성능 요약
66

7-
메모리: 0.0 MB, 시간: 0.00 ms
7+
메모리: undefined, 시간:
88

99
### 구분
1010

1111
코딩테스트 연습 > GROUP BY
1212

1313
### 채점결과
1414

15-
Empty
15+
합계: 100.0 / 100.0
1616

1717
### 제출 일자
1818

19-
2025년 12월 26일 22:08:22
19+
2026년 06월 10일 13:08:12
2020

2121
### 문제 설명
2222

Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
SELECT CAR_ID,
2-
max(case
3-
when '2022-10-16' between start_date and end_date then '대여중'
4-
else '대여 가능'
5-
end) as AVAILABLITY
6-
FROM CAR_RENTAL_COMPANY_RENTAL_HISTORY
2+
CASE
3+
WHEN CAR_ID in (SELECT CAR_ID FROM CAR_RENTAL_COMPANY_RENTAL_HISTORY WHERE '2022-10-16' BETWEEN START_DATE and END_DATE) THEN "대여중"
4+
ELSE "대여 가능"
5+
END as AVAILABLITY
6+
FROM CAR_RENTAL_COMPANY_RENTAL_HISTORY
77
GROUP BY CAR_ID
8-
ORDER BY CAR_ID DESC
8+
ORDER BY CAR_ID DESC

0 commit comments

Comments
 (0)