read_parquet()
Read typed columns from a Parquet file directly in a FROM clause, selecting and filtering the fields needed by your query.
Reference: Haybarn WASM 2.0.0-rc12
Arguments & returns
3 overloadsread_parquet(path, named arguments)
Table
Named arguments
Pass these after positional arguments, using name := value.
| Argument | Type |
|---|---|
allow_empty := | BOOLEAN |
binary_as_string := | BOOLEAN |
bound_schema := | ANY |
can_have_nan := | BOOLEAN |
column_statistics := | ANY |
compression := | VARCHAR |
debug_use_openssl := | BOOLEAN |
encryption_config := | ANY |
explicit_cardinality := | UBIGINT |
file_row_number := | BOOLEAN |
filename := | ANY |
hive_partitioning := | BOOLEAN |
hive_types := | ANY |
hive_types_autocast := | BOOLEAN |
int96_as := | VARCHAR |
parquet_version := | VARCHAR |
prefetch_strategy := | VARCHAR |
schema := | ANY |
union_by_name := | BOOLEAN |
utf8_validation := | VARCHAR |
read_parquet(paths, named arguments)
Table
| Overload link | paths |
Returns |
|---|---|---|
| #03 | ANY[] |
TABLE |
Named arguments
Pass these after positional arguments, using name := value.
| Argument | Type |
|---|---|
allow_empty := | BOOLEAN |
binary_as_string := | BOOLEAN |
bound_schema := | ANY |
can_have_nan := | BOOLEAN |
column_statistics := | ANY |
compression := | VARCHAR |
debug_use_openssl := | BOOLEAN |
encryption_config := | ANY |
explicit_cardinality := | UBIGINT |
file_row_number := | BOOLEAN |
filename := | ANY |
hive_partitioning := | BOOLEAN |
hive_types := | ANY |
hive_types_autocast := | BOOLEAN |
int96_as := | VARCHAR |
parquet_version := | VARCHAR |
prefetch_strategy := | VARCHAR |
schema := | ANY |
union_by_name := | BOOLEAN |
utf8_validation := | VARCHAR |
Query Parquet files with SQL
Read typed columns from a Parquet file directly in a FROM clause, selecting and filtering the fields needed by your query.
Parquet stores column types and NULL values. The example writes a tiny file into the browser engineβs virtual filesystem before reading it. A unique filename lets it run repeatedly.
Guide example Β· Run to view results.
| product | quantity |
|---|---|
apple | NULL |
Watch for: When reading files with different schemas, decide whether union_by_name is appropriate. It aligns columns by name and fills absent columns with NULL.
Example
Guide example Β· Run to view results.