基础文件更新一下配置
This commit is contained in:
+1
-1
@@ -8,7 +8,7 @@ from sqlalchemy.orm import sessionmaker
|
||||
# 1. 配置 MySQL 数据库连接 URL
|
||||
# 格式:mysql+pymysql://用户名:密码@主机:端口/数据库名?编码
|
||||
# 请将下面的 'root', '123456', 'localhost', '3306', 'test_db' 替换为你自己的实际信息
|
||||
SQLALCHEMY_DATABASE_URL = "mysql+pymysql://root:123456@localhost:3306/test_db"
|
||||
SQLALCHEMY_DATABASE_URL = "mysql+pymysql://root:123456@localhost:3306/max_code_sms"
|
||||
|
||||
# 2. 创建数据库引擎
|
||||
# - pool_pre_ping=True 表示每次从连接池取出连接前先 ping 一下,防止使用已断开的连接
|
||||
|
||||
Reference in New Issue
Block a user