【问题标题】:How to query on parquet files using pyarrow如何使用 pyarrow 查询镶木地板文件
【发布时间】:2021-12-06 02:24:52
【问题描述】:

我有一个包含 35 列的镶木地板文件,我必须使用 pyarrow 检查列中是否存在特定值。有人知道该怎么做吗?

【问题讨论】:

    标签: python pandas filter pyarrow fastparquet


    【解决方案1】:

    dataset 文档中的示例可能有用:

    类似:

    dataset = ds.dataset(base / "parquet_dataset", format="parquet")
    dataset.to_table(columns=['a'], filter=ds.field('a') >= 7).to_table
    

    【讨论】:

      猜你喜欢
      • 2018-04-17
      • 2018-05-06
      • 2021-10-28
      • 2018-08-08
      • 2019-02-05
      • 2019-10-27
      • 1970-01-01
      • 2021-08-31
      • 2020-01-16
      相关资源
      最近更新 更多