반응형
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
- math
- Tkinter
- array
- GIT
- Java
- Kotlin
- Excel
- list
- google apps script
- string
- 파이썬
- dataframe
- Google Excel
- PANDAS
- Mac
- Apache
- PostgreSQL
- Google Spreadsheet
- django
- c#
- gas
- hive
- numpy
- Python
- Github
- SQL
- Redshift
- matplotlib
- PySpark
Archives
- Today
- Total
목록TO_CHAR (1)
달나라 노트
Redshift : to_char (timestamp 또는 date를 문자로 변환)
to_char(date_timestamp, format) to_char는 위처럼 2개의 parameter를 받습니다. date_timestamp = 날짜 데이터나 timestamp 데이터를 의미합니다. format = date_timestamp를 문자로 변환할 때 어떠한 형식으로 변환할지를 나타냅니다. select sysdate; - Output 2021-01-22 15:24:48.315132 select current_date; - Output 2021-01-22 Redshift에선 sysdate를 이용해 현재 시점의 날짜, 시간 데이터를 얻을 수 있고, current_date를 통해 오늘 날짜를 얻을 수 있습니다. 이를 이용해서 to_char를 테스트해보겠습니다. select to_char(sysda..
SQL/Redshift
2021. 1. 22. 15:28