Views 15088 Votes 0 Comment 0
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print
?

Shortcut

PrevPrev Article

NextNext Article

Larger Font Smaller Font Up Down Go comment Print

서브쿼리를 이용한 초간단 통계 쿼리 예제

SELECT 
    SUM(
        DECODE(hope,1,1,0) hope1,
        DECODE(hope,2,1,0) hope2,
        DECODE(hope,3,1,0) hope3,
        DECODE(hope,4,1,0) hope4 
    )
    FROM cist_app
GROUP BY hope;

?

List of Articles
No. Category Subject Author Date Views
7 Database [mysql] DB->Text, Text->DB 변환 hooni 2003.04.23 12129
6 Database [sql] 간단한 SQL 문법 정리 hooni 2003.04.23 12551
5 Database [mysql] error while loading shared libraries: libmysqlclient.so.10: hooni 2003.04.23 12663
4 Database [mysql] 쓰레드가 계속 쌓이기 시작하고 사라지지 않을때.. hooni 2003.04.23 12787
» Database [sql] 간단한 통계 서브쿼리 예제.. hooni 2013.04.23 15088
2 Database [mysql] 쿼리 로그 저장 매뉴얼 file hooni 2013.04.23 15216
1 Database [mysql] 접속과 테이블 생성 간단한 설명.. hooni 2003.04.23 18655
Board Pagination Prev 1 2 Next
/ 2