- table create_all
- continue...
https://docs.sqlalchemy.org/en/14/core/metadata.html
-
pyecharts == 0.5.3
-
python3不再支持 mysql库了,需要使用pymysql; 修改为engine=create_engine('mysql+pymysql://root:password@localhost:3306/test')就可以了
>>> str
'2020-12-20'
>>> atime = time.mktime(time.strptime(str, '%Y-%m-%d'))
>>> atime
1608393600.0
>>> time.ctime(atime)
'Sun Dec 20 00:00:00 2020'
now.timestamp()
mysql> show variables like 'character_set_%';
+--------------------------+----------------------------+
| Variable_name | Value |
+--------------------------+----------------------------+
| character_set_client | latin1 |
| character_set_connection | latin1 |
| character_set_database | latin1 |
| character_set_filesystem | binary |
| character_set_results | latin1 |
| character_set_server | latin1 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+
8 rows in set (0.00 sec)
mysql> status
--------------
mysql Ver 14.14 Distrib 5.7.32, for Linux (x86_64) using EditLine wrapper
Connection id: 247
Current database: cmccb2b
Current user: root@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ''
Using delimiter: ;
Server version: 5.7.32 MySQL Community Server (GPL)
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: latin1
Client characterset: latin1
Conn. characterset: latin1
UNIX socket: /var/run/mysqld/mysqld.sock
Uptime: 2 days 3 hours 11 min 59 sec
Threads: 9 Questions: 5348 Slow queries: 0 Opens: 294 Flush tables: 1 Open tables: 182 Queries per second avg: 0.029
--------------
SQLALCHEMY_DATABASE_URI = 'mysql+pymysql://root:123456@localhost:3306/cmccb2b?charset=utf8'