在马盖特的沙滩上。
我无法将虚无和虚无
结合起来。
肮脏的双手的破裂的指甲。
我们卑微的人
能期待什么。
啦啦
于是我来到迦太基
烧啊烧啊烧啊烧啊
哦主啊你救拔我
主啊你救拔
烧啊
——T.S. Eliot《荒原 火的布道》III. The Fire Sermon
“On Margate Sands.
I can connect
Nothing with nothing.
The broken fingernails of dirty hands.
My people humble people who expect
Nothing.”
la la
To Carthage then I came
Burning burning burning burning
O Lord Thou pluckest me out
O Lord Thou pluckest
burning
我无法将虚无和虚无
结合起来。
肮脏的双手的破裂的指甲。
我们卑微的人
能期待什么。
啦啦
于是我来到迦太基
烧啊烧啊烧啊烧啊
哦主啊你救拔我
主啊你救拔
烧啊
——T.S. Eliot《荒原 火的布道》III. The Fire Sermon
“On Margate Sands.
I can connect
Nothing with nothing.
The broken fingernails of dirty hands.
My people humble people who expect
Nothing.”
la la
To Carthage then I came
Burning burning burning burning
O Lord Thou pluckest me out
O Lord Thou pluckest
burning
#工作笔记#Django环境里连接SQLServer2019的2种方式:
首先是网络上介绍的方法:
1 需要安装pymssql包
pip install pymssql
使用方法:
import pymssql
conn=pymssql.connect(host='127.0.0.1',user='user',password='password',database='MyDB')
cur=conn.cursor()
cur.execute('select * from table1')#如果是插入、删除、更新语句切记要写提交命令con.commit()
print (cur.fetchall())
cur.close()
conn.close()
------------------------------------------------------------------------------
2 安装必要的组件:
pip install django-sqlserver django-pytds pyodbc django-pyodbc pypiwin32
修改settings.py的DATABASES:
DATABASES = {
# 'default': {
# 'ENGINE': 'django.db.backends.sqlite3',
# 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
# }
'default': {
'ENGINE': 'sqlserver',
'NAME': 'MyDB',
'HOST': '127.0.0.1',
'PORT': '1433',
'USER': 'user',
'PASSWORD': 'password,
'OPTIONS': {
'DRIVER': 'SQL Server Native Client 10.0',
},
}
}
-----------------------------------------------------------------------------------
我实际测试的情况见图,第二种方法可能是因为版本更新的缘故,需要安装的包名字有所不同:
pip install django-mssql-backend
具体详情可查看其项目官网:https://t.cn/A6x4g8yU
另外,需要注意
'OPTIONS': {
'driver': 'SQL Server Native Client 11.0',
'driver': 'ODBC Driver 17 for SQL Server'
}
里的驱动程序driver要与windows里的“ODBC数据源管理程序”中所安装的驱动程序一致,见图3。
首先是网络上介绍的方法:
1 需要安装pymssql包
pip install pymssql
使用方法:
import pymssql
conn=pymssql.connect(host='127.0.0.1',user='user',password='password',database='MyDB')
cur=conn.cursor()
cur.execute('select * from table1')#如果是插入、删除、更新语句切记要写提交命令con.commit()
print (cur.fetchall())
cur.close()
conn.close()
------------------------------------------------------------------------------
2 安装必要的组件:
pip install django-sqlserver django-pytds pyodbc django-pyodbc pypiwin32
修改settings.py的DATABASES:
DATABASES = {
# 'default': {
# 'ENGINE': 'django.db.backends.sqlite3',
# 'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
# }
'default': {
'ENGINE': 'sqlserver',
'NAME': 'MyDB',
'HOST': '127.0.0.1',
'PORT': '1433',
'USER': 'user',
'PASSWORD': 'password,
'OPTIONS': {
'DRIVER': 'SQL Server Native Client 10.0',
},
}
}
-----------------------------------------------------------------------------------
我实际测试的情况见图,第二种方法可能是因为版本更新的缘故,需要安装的包名字有所不同:
pip install django-mssql-backend
具体详情可查看其项目官网:https://t.cn/A6x4g8yU
另外,需要注意
'OPTIONS': {
'driver': 'SQL Server Native Client 11.0',
'driver': 'ODBC Driver 17 for SQL Server'
}
里的驱动程序driver要与windows里的“ODBC数据源管理程序”中所安装的驱动程序一致,见图3。
【苹果将在年末假期保持开启 App Store Connect 提交】
11 月 8 日,苹果开发者官网的最新消息显示,在今年岁末的假期期间,苹果会在 App Store Connect 中继续接受 app 提交。按照以往的传统,苹果会在圣诞假期期间关闭 App Store Connect 一周,去年苹果从 12 月 23 日到 27 日关闭了 App Store Connect。
「请确保您的 app 已做好更新,并为 App Store 上这个最繁忙的季节做好准备。预计届时会有大量的 app 提交审核,请提前规划,尽早提交有时限性的内容。」
需要注意的是,在 11 月 24 日至 28 日以及 12 月 23 日至 27 日期间,完成审核可能需时较长。
11 月 8 日,苹果开发者官网的最新消息显示,在今年岁末的假期期间,苹果会在 App Store Connect 中继续接受 app 提交。按照以往的传统,苹果会在圣诞假期期间关闭 App Store Connect 一周,去年苹果从 12 月 23 日到 27 日关闭了 App Store Connect。
「请确保您的 app 已做好更新,并为 App Store 上这个最繁忙的季节做好准备。预计届时会有大量的 app 提交审核,请提前规划,尽早提交有时限性的内容。」
需要注意的是,在 11 月 24 日至 28 日以及 12 月 23 日至 27 日期间,完成审核可能需时较长。
✋热门推荐