einsone opened a new issue, #35424:
URL: https://github.com/apache/arrow/issues/35424
### Describe the usage question you have. Please include as many useful
details as possible.
why different columns order result in different schema?
the following code raise:
pyarrow.lib.ArrowInvalid: Schema at index 1 was different:
```python
import pandas as pd
import pyarrow as pa
print(pa.show_info())
df1 = pd.DataFrame({
"col1": [1,2,3,4,5],
"col2": ["A", "B", "C", "D", "E"],
})
df2 = pd.DataFrame({
"col2": ["A", "B", "C", "D", "E"],
"col1": [1,2,3,4,5],
})
tbl1 = pa.Table.from_pandas(df1, preserve_index=False)
tbl2 = pa.Table.from_pandas(df2, preserve_index=False)
tbl3 = pa.concat_tables([tbl1, tbl2])
```
### Component(s)
C++, Python
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]