Skip to content

fix(oracle): cast string to int for the precision and scale of decimal#11200

Merged
cpcloud merged 1 commit intoibis-project:mainfrom
goldmedal:fix/oracle-number-ps
May 14, 2025
Merged

fix(oracle): cast string to int for the precision and scale of decimal#11200
cpcloud merged 1 commit intoibis-project:mainfrom
goldmedal:fix/oracle-number-ps

Conversation

@goldmedal
Copy link
Copy Markdown
Contributor

Description of changes

The type mapping for Oracle number type can't handle the number type with precision and scale.
For example, given a table like

CREATE TABLE "number_table" ("number_8_2" NUMBER(8, 2))

In the Ibis side, we will get Number('8', '2'), we should cast them to int from string.

Issues closed

No corresponding issue currently.

@github-actions github-actions bot added tests Issues or PRs related to tests oracle The Oracle backend labels May 9, 2025
@goldmedal
Copy link
Copy Markdown
Contributor Author

E       AssertionError: assert 'ibis_temp_memtable_qkkxzqsisjebxftctnvv4y74yi' not in ['astronauts', 'awards_players', 'batting', 'diamonds', 'functional_alltypes', 'ibis_pandas_memtable_3g6g3sg5lbdvdi36mmyc4hqtde', ...]
E        +  where ['astronauts', 'awards_players', 'batting', 'diamonds', 'functional_alltypes', 'ibis_pandas_memtable_3g6g3sg5lbdvdi36mmyc4hqtde', ...] = list_tables()
E        +    where list_tables = <ibis.backends.exasol.Backend object at 0x7f8801bb2370>.list_tables

I don't understand the CI failure. I just followed test_blob_raw to add the test 🤔.
Could anyone tell me how to fix it? Thanks.

Copy link
Copy Markdown
Member

@cpcloud cpcloud left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@cpcloud cpcloud merged commit 969453e into ibis-project:main May 14, 2025
109 of 111 checks passed
@goldmedal goldmedal deleted the fix/oracle-number-ps branch May 15, 2025 02:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

oracle The Oracle backend tests Issues or PRs related to tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants