Skip to content

Commit b35c50b

Browse files
Doc tweaks.
1 parent 724717e commit b35c50b

File tree

12 files changed

+1040
-1047
lines changed

12 files changed

+1040
-1047
lines changed

README.md

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,23 @@
11
# python-oracledb
22

3-
Python-oracledb is a [Python programming language][python] extension module
4-
allowing Python programs to connect to [Oracle Database][oracledb].
5-
Python-oracledb is the new name for the obsolete cx_Oracle driver.
3+
Python-oracledb is an open-source [Python][python] extension module allowing
4+
Python programs to connect to [Oracle Database][oracledb]. The module conforms
5+
to the [Python Database API 2.0 specification][pep249] with a considerable
6+
number of additions and a couple of minor exclusions, see the [feature
7+
list][features]. It is maintained by Oracle.
68

7-
Python-oracledb uses the same Python DB API as cx_Oracle, and has many new
8-
features.
9+
Python-oracledb is used for executing SQL and PL/SQL; for calling NoSQL-style
10+
document APIs; for working with data frames; for receiving database
11+
notifications and messages; and for starting and stopping the database. It has
12+
features for high availability and security. It is used by many Python
13+
Frameworks, SQL Generators, ORMs, and libraries.
914

10-
The module conforms to the [Python Database API 2.0 specification][pep249] with
11-
a considerable number of additions and a couple of minor exclusions, see the
12-
[feature list][features].
15+
Synchronous and [concurrent][concurrent] coding styles are supported. Database
16+
operations can optionally be [pipelined][pipelining].
1317

14-
Synchronous and [concurrent][concurrent] coding styles are supported.
18+
Python-oracledb is the successor to the now obsolete cx_Oracle driver.
1519

16-
Python-oracledb is available under an open source license, see below.
17-
18-
## Installation
20+
## Python-oracledb Installation
1921

2022
Run:
2123

@@ -127,4 +129,5 @@ See [LICENSE][license], [THIRD_PARTY_LICENSES][tplicense], and
127129
[installation]: https://python-oracledb.readthedocs.io/en/latest/user_guide/installation.html
128130
[features]: https://oracle.github.io/python-oracledb/#features
129131
[concurrent]: https://python-oracledb.readthedocs.io/en/latest/user_guide/asyncio.html
132+
[pipelining]: https://python-oracledb.readthedocs.io/en/latest/user_guide/asyncio.html#pipelining-database-operations
130133
[pypi]: https://pypi.org/project/oracledb

doc/src/index.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,21 +31,23 @@ User Guide
3131
user_guide/json_data_type.rst
3232
user_guide/xml_data_type.rst
3333
user_guide/vector_data_type.rst
34+
user_guide/dataframes.rst
3435
user_guide/soda.rst
3536
user_guide/aq.rst
3637
user_guide/cqn.rst
3738
user_guide/two_phase_commit.rst
3839
user_guide/startup.rst
3940
user_guide/ha.rst
40-
user_guide/globalization.rst
4141
user_guide/asyncio.rst
42+
user_guide/globalization.rst
4243
user_guide/exception_handling.rst
4344
user_guide/tracing.rst
4445
user_guide/extending.rst
4546
user_guide/troubleshooting.rst
4647
user_guide/appendix_a.rst
4748
user_guide/appendix_b.rst
4849
user_guide/appendix_c.rst
50+
user_guide/appendix_d.rst
4951

5052
API Manual
5153
==========

doc/src/release_notes.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1619,16 +1619,16 @@ Common Changes
16191619
oracledb 1.0.0 (May 2022)
16201620
-------------------------
16211621

1622-
#) Renamed cx_Oracle to python-oracledb. See :ref:`upgradecomparison`.
1622+
#) Renamed cx_Oracle to python-oracledb. See :ref:`upgrading83`.
16231623
#) Python-oracledb is a 'Thin' driver by default that connects directly
16241624
to Oracle Database. Optional use of Oracle Client libraries enables a
16251625
:ref:`'Thick' mode <enablingthick>` with some additional functionality.
16261626
Both modes support the Python Database API v2.0 Specification.
16271627
#) Added a :attr:`Connection.thin` attribute which shows whether the
16281628
connection was established in the python-oracledb Thin mode or Thick mode.
1629-
#) Creating connections or connection pools now requires :ref:`keyword
1630-
parameters <connectdiffs>` be passed. This brings python-oracledb into
1631-
compliance with the Python Database API specification PEP 249.
1629+
#) Creating connections or connection pools now requires keyword parameters be
1630+
passed. This brings python-oracledb into compliance with the Python
1631+
Database API specification PEP 249.
16321632
#) Threaded mode is now always enabled for standalone connections (Thick
16331633
mode).
16341634
#) The function :func:`oracledb.init_oracle_client()` must now always be

doc/src/user_guide/appendix_a.rst

Lines changed: 37 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ enable Thick mode.
1515

1616
The following table summarizes the Oracle Database features supported by
1717
python-oracledb Thin and Thick modes, and by the obsolete cx_Oracle driver.
18-
For more details see :ref:`driverdiff` and :ref:`compatibility`.
18+
For more details see :ref:`driverdiff` and :ref:`upgrading83`.
1919

2020
.. list-table-with-summary:: Features Supported by python-oracledb and cx_Oracle 8.3
2121
:header-rows: 1
@@ -369,137 +369,140 @@ example when binding numeric values.
369369
:header-rows: 1
370370
:class: wy-table-responsive
371371
:align: center
372-
:summary: The first column displays the database data type. The second column displays the python-oracledb constant Name. The third column contains notes. The fourth column shows Python types that can be used.
372+
:summary: The first column displays the database data type. The second column displays the python-oracledb constant Name. The third column shows Python types that can be used. The fourth column contains notes.
373373

374374
* - Oracle Database Type
375375
- python-oracledb Constant Name
376-
- Notes
377376
- Supported Python Types
377+
- Notes
378378
* - VARCHAR2
379379
- :data:`~oracledb.DB_TYPE_VARCHAR`
380-
- No relevant notes
381380
- bytes, str
381+
- No relevant notes
382382
* - NVARCHAR2
383383
- :data:`~oracledb.DB_TYPE_NVARCHAR`
384-
- No relevant notes
385384
- bytes, str
385+
- No relevant notes
386386
* - NUMBER, FLOAT
387387
- :data:`~oracledb.DB_TYPE_NUMBER`
388-
- No relevant notes
389388
- bool, int, float, decimal.Decimal
389+
- No relevant notes
390390
* - DATE
391391
- :data:`~oracledb.DB_TYPE_DATE`
392-
- No relevant notes
393392
- datetime.date, datetime.datetime
393+
- No relevant notes
394394
* - BOOLEAN (PL/SQL and Oracle Database 23ai SQL)
395395
- :data:`~oracledb.DB_TYPE_BOOLEAN`
396-
- No relevant notes
397396
- Any type convertible to bool
397+
- No relevant notes
398398
* - BINARY_DOUBLE
399399
- :data:`~oracledb.DB_TYPE_BINARY_DOUBLE`
400-
- No relevant notes
401400
- bool, int, float, decimal.Decimal
401+
- No relevant notes
402402
* - BINARY_FLOAT
403403
- :data:`~oracledb.DB_TYPE_BINARY_FLOAT`
404-
- No relevant notes
405404
- bool, int, float, decimal.Decimal
405+
- No relevant notes
406406
* - TIMESTAMP
407407
- :data:`~oracledb.DB_TYPE_TIMESTAMP`
408-
- No relevant notes
409408
- datetime.date, datetime.datetime
409+
- No relevant notes
410410
* - TIMESTAMP WITH TIME ZONE
411411
- :data:`~oracledb.DB_TYPE_TIMESTAMP_TZ`
412-
- No relevant notes
413412
- datetime.date, datetime.datetime
413+
- No relevant notes
414414
* - TIMESTAMP WITH LOCAL TIME ZONE
415415
- :data:`~oracledb.DB_TYPE_TIMESTAMP_LTZ`
416-
- No relevant notes
417416
- datetime.date, datetime.datetime
417+
- No relevant notes
418418
* - INTERVAL YEAR TO MONTH
419419
- :data:`~oracledb.DB_TYPE_INTERVAL_YM`
420-
- No relevant notes
421420
- :ref:`oracledb.IntervalYM <interval_ym>`
421+
- No relevant notes
422422
* - INTERVAL DAY TO SECOND
423423
- :data:`~oracledb.DB_TYPE_INTERVAL_DS`
424-
- No relevant notes
425424
- datetime.timedelta
425+
- No relevant notes
426426
* - RAW
427427
- :data:`~oracledb.DB_TYPE_RAW`
428-
- No relevant notes
429428
- bytes, str
429+
- No relevant notes
430430
* - LONG
431431
- :data:`~oracledb.DB_TYPE_LONG`
432-
- No relevant notes
433432
- bytes, str
433+
- No relevant notes
434434
* - LONG RAW
435435
- :data:`~oracledb.DB_TYPE_LONG_RAW`
436-
- No relevant notes
437436
- bytes, str
437+
- No relevant notes
438438
* - ROWID
439439
- :data:`~oracledb.DB_TYPE_ROWID`
440-
- No relevant notes
441440
- bytes, str
441+
- No relevant notes
442442
* - UROWID
443443
- :data:`~oracledb.DB_TYPE_ROWID`, :data:`~oracledb.DB_TYPE_UROWID` (only supported in python-oracledb Thin mode)
444-
- May show :data:`~oracledb.DB_TYPE_UROWID` in metadata. See :ref:`Query Metadata Differences <querymetadatadiff>`.
445444
- bytes, str
445+
- May show :data:`~oracledb.DB_TYPE_UROWID` in metadata. See :ref:`Query Metadata Differences <querymetadatadiff>`.
446446
* - CHAR
447447
- :data:`~oracledb.DB_TYPE_CHAR`
448-
- No relevant notes
449448
- bytes, str
449+
- No relevant notes
450450
* - BLOB
451451
- :data:`~oracledb.DB_TYPE_BLOB`
452-
- No relevant notes
453452
- :ref:`oracledb.LOB <lobobj>`, bytes, str
453+
- No relevant notes
454454
* - CLOB
455455
- :data:`~oracledb.DB_TYPE_CLOB`
456-
- No relevant notes
457456
- :ref:`oracledb.LOB <lobobj>`, bytes, str
457+
- No relevant notes
458458
* - NCHAR
459459
- :data:`~oracledb.DB_TYPE_NCHAR`
460-
- No relevant notes
461460
- bytes, str
461+
- No relevant notes
462462
* - NCLOB
463463
- :data:`~oracledb.DB_TYPE_NCLOB`, :data:`~oracledb.DB_TYPE_LONG_NVARCHAR` (if fetching NCLOB as a string)
464-
- No relevant notes
465464
- :ref:`oracledb.LOB <lobobj>`, bytes, str
465+
- No relevant notes
466466
* - BFILE
467467
- :data:`~oracledb.DB_TYPE_BFILE`
468-
- Can fetch a BFILE object and insert that object in a table. Cannot create BFILE objects.
469468
- :ref:`oracledb.LOB <lobobj>`, bytes
469+
- Can fetch a BFILE object and insert that object in a table. Cannot create BFILE objects.
470470
* - JSON
471471
- :data:`~oracledb.DB_TYPE_JSON`
472-
- No relevant notes
473472
- Any type convertible to Oracle JSON
473+
- No relevant notes
474474
* - REF CURSOR (PL/SQL OR nested cursor)
475475
- :data:`~oracledb.DB_TYPE_CURSOR`
476-
- No relevant notes
477476
- :ref:`oracledb.Cursor <cursorobj>`
477+
- No relevant notes
478478
* - PLS_INTEGER
479479
- :data:`~oracledb.DB_TYPE_BINARY_INTEGER`
480-
- No relevant notes
481480
- bool, int, float, decimal.Decimal
481+
- No relevant notes
482482
* - BINARY_INTEGER
483483
- :data:`~oracledb.DB_TYPE_BINARY_INTEGER`
484-
- No relevant notes
485484
- bool, int, float, decimal.Decimal
485+
- No relevant notes
486486
* - REF
487487
- n/a
488-
- Not supported in python-oracledb Thin mode
489488
- n/a
489+
- Not supported in python-oracledb Thin mode
490490
* - XMLType
491491
- :data:`~oracledb.DB_TYPE_XMLTYPE`
492-
- May need to use ``xmltype.getclobval()`` to fetch in python-oracledb Thick mode. See :ref:`xmldatatype`
493492
- bytes, str
493+
- May need to use ``xmltype.getclobval()`` to fetch in python-oracledb Thick mode. See :ref:`xmldatatype`
494494
* - User-defined types (object type, VARRAY, records, collections, SDO_*types)
495495
- :data:`~oracledb.DB_TYPE_OBJECT`
496-
- No relevant notes
497496
- OBJECT of specific type
497+
- No relevant notes
498498
* - VECTOR
499499
- :data:`~oracledb.DB_TYPE_VECTOR`
500-
- No relevant notes
501500
- array.array
501+
- No relevant notes
502502

503503
Binding of contiguous PL/SQL Index-by BINARY_INTEGER arrays of string, number, and date are
504504
supported in python-oracledb Thin and Thick modes. Use :meth:`Cursor.arrayvar()` to build
505505
these arrays.
506+
507+
When fetching :ref:`data frames <dataframeformat>`, see :ref:`Data Frame Type
508+
Mapping <dftypemapping>` for type information.

0 commit comments

Comments
 (0)