반응형
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
- matplotlib
- hive
- django
- string
- google apps script
- Kotlin
- SQL
- c#
- Python
- math
- dataframe
- Mac
- PANDAS
- 파이썬
- Google Spreadsheet
- numpy
- Github
- PostgreSQL
- Tkinter
- Redshift
- array
- GIT
- Google Excel
- Java
- gas
- Excel
- Apache
- PySpark
- list
Archives
- Today
- Total
목록SQL/Redshift (70)
달나라 노트
Redshift : RANK, DENSE_RANK, ROW_NUMBER (순위, 컬럼번호 부여하기)
RANK() OVER() 예시 테이블 Table Name : salary_list id part name salary 1 First_Part One 1000 2 First_Part Two 1900 3 First_Part Three 1400 4 First_Part Four 1700 5 First_Part Five 1400 6 Second_Part Six 1900 7 Second_Part Seven 1200 8 Second_Part Eight 1200 9 Second_Part Nine 1200 10 Second_Part Ten 1300 SELECT *, RANK() OVER(ORDER BY salary DESC) AS rank FROM salary_list Result Set id part name sala..
SQL/Redshift
2020. 12. 17. 02:12