일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- PANDAS
- PostgreSQL
- c#
- google apps script
- 파이썬
- hive
- Github
- GIT
- math
- Kotlin
- PySpark
- Google Excel
- list
- Mac
- dataframe
- django
- Apache
- Python
- SQL
- Excel
- gas
- matplotlib
- Java
- Google Spreadsheet
- array
- Tkinter
- string
- numpy
- Redshift
- Today
- Total
목록분류 전체보기 (847)
달나라 노트
import ftplib s3_host = '11.111.111.111' s3_user_id = 'user_1' s3_user_password = 'pw_1' ftp = ftplib.FTP() ftp.encoding = 'utf-8' ftp.connect(s3_host) # connect to s3 ftp.login(s3_user_id, s3_user_password) # login to s3 print('Current directory :', ftp.pwd()) # make directory in s3 try: ftp.mkd('/test1/test2/test3/') except Exception as e: print(e) ftp.cwd('/test1/test2/test3/') print('New dir..
import ftplib s3_host = '11.111.111.111' s3_user_id = 'user_1' s3_user_password = 'pw_1' ftp = ftplib.FTP() ftp.encoding = 'utf-8' ftp.connect(s3_host) # connect to s3 ftp.login(s3_user_id, s3_user_password) # login to s3 # show current directory print('Current directory :', ftp.pwd()) ftp.quit() # quit s3 - Output Current directory : / ftplib의 pwd는 현재 디렉토리를 출력해줍니다. 로그인한 후의 Directory는 root direc..
import ftplib s3_host = '11.111.111.111' s3_user_id = 'user_1' s3_user_password = 'pw_1' ftp = ftplib.FTP() ftp.encoding = 'utf-8' ftp.connect(s3_host) # connect to s3 ftp.login(s3_user_id, s3_user_password) # login to s3 ftp.quit() # quit s3 ftplib를 이용한 s3 server로의 로그인은 위처럼 가능합니다.
datediff(단위, start_date, end_date) datediff 함수는 위처럼 사용할 수 있습니다. datediff 함수는 start_date에서 end_date 간의 차이값을 명시한 단위로 반환해주죠. 정확히 말하면 end_date - start_date의 결과를 명시한 단위의 수치로 나타내줍니다. 따라서 start_date end_date 일 경우 결과값은 음수일 것입니다. select datediff(day, to_date('20210101', 'yyyymmdd'), to_date('20210110', 'yyyymmdd')) -> 9 select datediff(day, to_date('20210110', 'y..