Open
Description
- Describe your new request in detail
This is already kind of known, filing as separate issue so it's easy to track down.
It's currently not possible to enforce a schema on top of OracleArrowArray, example below.
oracle_df = conn.fetch_df_all(statement="select 1 n1 from dual", arraysize=2)
df = pa.Table.from_arrays(arrays=oracle_df.column_arrays(), schema=pa.schema([("n1", pa.int8())]))
File "pyarrow/table.pxi", line 4893, in pyarrow.lib.Table.from_arrays
File "pyarrow/table.pxi", line 1622, in pyarrow.lib._sanitize_arrays
File "pyarrow/array.pxi", line 405, in pyarrow.lib.asarray
File "pyarrow/array.pxi", line 273, in pyarrow.lib.array
File "src/oracledb/interchange/nanoarrow_bridge.pyx", line 500, in oracledb.interchange.nanoarrow_bridge.OracleArrowArray.__arrow_c_array__
NotImplementedError: requested_schema
This would be especially useful when casting to ints or date32, there are ways around it but they are a bit annoying (and slow).
- Give supporting information about tools and operating systems. Give relevant product version numbers
Not applicable