[ 
https://issues.apache.org/jira/browse/ARROW-9461?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated ARROW-9461:
----------------------------------
    Labels: pull-request-available  (was: )

> [Rust] Reading Date32 and Date64 errors - they are incorrectly converted to 
> RecordBatch
> ---------------------------------------------------------------------------------------
>
>                 Key: ARROW-9461
>                 URL: https://issues.apache.org/jira/browse/ARROW-9461
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: Rust
>            Reporter: Jorge
>            Assignee: Jorge
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Steps to reproduce:
> 1. Create a file `a.parquet` using the following code:
> {code:python}
> import pyarrow.parquet
> import numpy
> def _data_datetime(f):
>     data = numpy.array([
>         numpy.datetime64('2018-08-18 23:25'),
>         numpy.datetime64('2019-08-18 23:25'),
>         numpy.datetime64("NaT")
>     ])
>     data = numpy.array(data, dtype=f'datetime64[{f}]')
>     return data
> def _write_parquet(path, data):
>     table = pyarrow.Table.from_arrays([pyarrow.array(data)], names=['a'])
>     pyarrow.parquet.write_table(table, path)
>     return path
> _write_parquet('a.parquet', _data_datetime('D'))
> {code}
> 2. Write a small example to read it to RecordBatches
> 3. observe the error {{ArrowError(ParquetError("InvalidArgumentError(\"column 
> types must match schema types, expected Date32(Day) but found UInt32 at 
> column index 0\")"))}}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to