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
- 리스트교집합
- hashset
- route53
- WordPress
- 리스트합집합
- string_agg()
- awsconsole
- Java
- 리스트비교
- ansible
- Spring
- PostgreSQL
- wordpress블로그
- 리스트차집합
- 두개리스트비교
- Annotation
- enum
- AWS
- enumtype
- 중복제거
- 3tierarchitecture
- list중복제거
- 권한정책
- db
- 지옥같은git
- anymatch메서드
- 널포인터에러
- mybatis
- lightsail
- instance생성
Archives
- Today
- Total
Anyway
[DB] postgresql Count 함수 사용하기
SELECT COUNT(CASE WHEN score BETWEEN 9 AND 10 THEN 1 END) AS excellent_score, COUNT(CASE WHEN score BETWEEN 7 AND 8 THEN 1 END) AS good_score, COUNT(CASE WHEN score BETWEEN 1 AND 6 THEN 1 END) AS bad_score, COUNT((CASE WHEN score BETWEEN 1 AND 6 THEN 1 END) AND (CASE WHEN A = false AND B = false AND C = false THEN 1 END)) AS bad_score_unconfirmed, COUNT(CASE WHEN score IS NULL OR ..
Database
2024. 12. 19. 14:44