Count Rows In Parquet
Controlled node
Overview
Count rows in a Parquet file without returning its records.
Count Rows In Parquet returns the number of rows in a Parquet file from the project library.
Inputs
| Input | Type | Description |
|---|---|---|
| run | Event | Starts the count. |
| file | File | A Parquet file from the project library. Select it in the picker or connect a library file reference. If a list is supplied, only its first file is used. |
Outputs
| Output | Type | Description |
|---|---|---|
| count | Data | The numeric row count, or an object with an error field. |
| done | Event | Continues after the node finishes; check the data output for errors. |
Example
Select the file, connect Start to run, then connect count to Show's value input and done to Show's run input.
Use the count to plan pages or check a dataset before processing it. For example, a count of 250 can be read in pages of 100 with offsets 0, 100 and 200.
Use Read Parquet to retrieve the records themselves.
Check that count is a number before using it for arithmetic, comparisons or loop control. A missing, unsupported or unreadable file can return an error object instead.