oracle SQL 查询的标准 Python 模块是什么?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/5748610/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-18 23:26:41  来源:igfitidea点击:

What is the standard Python module for SQL queries?

pythonsqloracle

提问by ktm5124

I am wondering what is the standard Python module for SQL queries?

我想知道什么是 SQL 查询的标准 Python 模块?

I am writing queries for an Oracle database in particular. I am looking to write quick, easy, and direct queries, in the context of both scripts and small programs.

我正在为 Oracle 数据库编写查询。我希望在脚本和小程序的上下文中编写快速、简单和直接的查询。

回答by Ignacio Vazquez-Abrams

Each SQL database has their own module which implements DB-API 2.0. Oracle uses cx_Oracle.

每个 SQL 数据库都有自己的模块来实现DB-API 2.0。Oracle 使用cx_Oracle

回答by NPE

DB-API is the standard API for accessing SQL databases from Python.

DB-API 是从 Python 访问 SQL 数据库的标准 API。

The following page provides further information: http://wiki.python.org/moin/DatabaseProgramming/

以下页面提供了更多信息:http: //wiki.python.org/moin/DatabaseProgramming/