Skip to content

Commit 1d7d265

Browse files
committed
[level 3] Title: 자동차 대여 기록에서 대여중 / 대여 가능 여부 구분하기, Time: 0.00 ms, Memory: 0.0 MB -BaekjoonHub
1 parent acc7d44 commit 1d7d265

2 files changed

Lines changed: 10 additions & 8 deletions

File tree

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Empty
1616

1717
### 제출 일자
1818

19-
2025년 11월 05일 09:50:35
19+
2025년 11월 10일 10:20:48
2020

2121
### 문제 설명
2222

Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
1-
SELECT
2-
CAR_ID,
1+
SELECT
2+
car_id,
33
CASE
4-
WHEN SUM(CASE WHEN '2022-10-16' BETWEEN START_DATE AND END_DATE THEN 1 ELSE 0 END) > 0
5-
THEN '대여중'
4+
WHEN SUM(CASE
5+
WHEN '2022-10-16' BETWEEN start_date AND end_date THEN 1
6+
ELSE 0
7+
END) > 0 THEN '대여중'
68
ELSE '대여 가능'
7-
END AS AVAILABILITY
9+
END AS availability
810
FROM CAR_RENTAL_COMPANY_RENTAL_HISTORY
9-
GROUP BY CAR_ID
10-
ORDER BY CAR_ID DESC;
11+
GROUP BY car_id
12+
ORDER BY car_id DESC;

0 commit comments

Comments
 (0)