Skip to content
This repository has been archived by the owner on May 17, 2024. It is now read-only.

Switch from cx_Oracle to oracledb #681

Merged
merged 3 commits into from
Aug 22, 2023
Merged

Switch from cx_Oracle to oracledb #681

merged 3 commits into from
Aug 22, 2023

Conversation

nolar
Copy link
Collaborator

@nolar nolar commented Aug 15, 2023

cx_Oracle is officially deprecated since 2021 (2 years go) and no new released were made. The new official library is oracledb. This warning is the first sentence in cx_Oracle's docs.

New projects, such as data-diff, should use the new library. Luckily, oracledb is mostly a drop-in replacement for cx_Oracle, so no code changes are needed.

Besides, oracledb provides 2 modes: the "thin" mode and the "thick" mode. The latter (`"thick") one requires binary libraries, the former one ("thin") works in pure Python. This simplifies the Oracle usage for users.

`cx_Oracle` is officially deprecated since 2021 (2 years go) and no new released were made. The new official library is `oracledb`. This warning is the first sentence in cx_Oracle's docs.

New projects, such as data-diff, should use the new library. Luckily, `oracledb` is mostly a drop-in replacement for `cx_Oracle`, so no code changes are needed.

Besides, `oracledb` provides 2 modes: the "thin" mode and the "thick" mode. The latter (`"thick") one requires binary libraries, the former one ("thin") works in pure Python. This simplifies the Oracle usage for users.
Copy link
Contributor

@sungchun12 sungchun12 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So by default this driver is using "thin" mode. Is there ever a reason to use "thick" mode when data diffing?

@sungchun12
Copy link
Contributor

sungchun12 commented Aug 15, 2023

Quick chatgpt reference. May be worth adding thick mode into Datafold for xdb data diffing if thick mode has a significant performance boost.

image

@dlawin dlawin linked an issue Aug 22, 2023 that may be closed by this pull request
@dlawin dlawin merged commit 4b2ca27 into master Aug 22, 2023
6 checks passed
@nolar nolar deleted the oracle-via-oracledb branch September 5, 2023 18:50
@choudrybabu
Copy link

Hello @dlawin
is there a way to force Thick mode ?
as our oracle db pwd are case insensitive thin mode isnt working , can you please let me know if there is any alternative approach
i have tried my luck with our DBA team to make it case sensitive , but no luck

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add support for python-oracledb
4 participants