python 和 MySQL 之间的交互有推荐的方式吗?
python 和 MySQL 之间交互的推荐方式是什么?目前我正在使用 MySQLdb,并且我收到了 Oursql 的消息。但我问自己,是否有更合适的方法来管理这个问题。
What is the recommonded way to interact between python and MySQL? Currently I am using MySQLdb and I heared from Oursql. But I asked myself, if there is a more appropriate way to manage this.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
MySQLdb 是大多数人在较低级别使用的,但我们的sql 也很有趣。您可以使用更高级别的机制,例如
MySQLdb is what most people use at the lower level, but oursql is interesting too. You can use higher level mechanisms such as
我个人使用pymysql,但听说很多人使用MySQLdb。两者的行为方式非常相似,并且可以轻松互换。就我个人而言,(作为 python/MySQL QA)我还没有听说过/更不用说使用 OurSQL 了。
话虽如此,这实际上取决于您想要实现的目标。 Python 有大量的连接器和大量的附加功能来完成几乎任何事情; (并且)因此,重要的是要注意始终查看该组件的受欢迎程度以及其更新频率非常重要。
I personally use pymysql, but have heard a lot of people use MySQLdb. Both are very similar in the way they behave, and could easily be interchangeable. Personally, (working as a python/MySQL QA) I've yet to hear of / let alone work with OurSQL.
With that said, it honestly depends what you want to accomplish. Python has a lot of connectors, and a tons of bells and whistles to complete almost anything; (and) As such, it is important to note that it is important to always look at how popular the component is, as well as how frequently it gets updated.