Working with Parquet
The @frictionless-ts/table package provides efficient support for loading and saving data in Apache Parquet format. It uses Polars DataFrames for high-performance columnar data processing.
Installation
Section titled “Installation”npm install @frictionless-ts/tableBasic Usage
Section titled “Basic Usage”Loading Data
Section titled “Loading Data”import { loadParquetTable } from "@frictionless-ts/table"
// Load from local fileconst table = await loadParquetTable({ path: "data.parquet" })
// Load from remote URLconst table = await loadParquetTable({ path: "https://example.com/data.parquet"})
// Load multiple files (concatenated)const table = await loadParquetTable({ path: ["file1.parquet", "file2.parquet"]})Saving Data
Section titled “Saving Data”import { saveParquetTable } from "@frictionless-ts/table"
// Save as Parquet formatawait saveParquetTable(table, { path: "output.parquet" })