SmartQueryTools

Find Arg Max / Min in Parquet Files Online

Find the value of one column at the row where another column is maximum or minimum in Parquet files — directly in your browser. Optionally group by a category to get per-group results. No upload required.

How to find Arg Max / Min in Parquet files

  1. Drop your file onto the upload area. The first 200 rows are shown. The second column is preselected as the one to find the max of, and the first column as the one to return.
  2. Choose the operation: arg_max for the row with the highest value, or arg_min for the lowest.
  3. Pick the "Find max of this column" and "Return the value of this column" columns. A sentence under the settings describes the query in plain words.
  4. Optionally pick a Group by column for one result per group, and name the output column. Left blank, it is named like date_at_max_temp.
  5. Click Find Arg Max (or Find Arg Min), check the result table, and download it as CSV.

Your file is processed locally in your browser and is never uploaded. The free limit is 50 MB per file; larger files work if your device has the memory for them.

Worked example

A weather hobbyist logs daily readings from three stations and wants the date of the hottest day recorded at each one. One reading from Auckland failed and has no temperature.

Input (Parquet)

Parquet file (binary, columnar) — shown as a table with its schema

stationreading_datetemp_crain_mm
WLG2026-01-1421.40
WLG2026-01-1524.92.2
AKL2026-01-1426.10.4
AKL2026-01-15NULL5.8
AKL2026-01-1625.30
CHC2026-01-1529.80

Schema: station VARCHAR, reading_date DATE, temp_c DOUBLE, rain_mm DOUBLE

Settings

  • Operation: arg_max
  • Find max of this column: temp_c
  • Return the value of this column: reading_date
  • Group by: station
  • Output column name: left blank (auto-generated)

Result

stationreading_date_at_max_temp_c
AKL2026-01-14
CHC2026-01-15
WLG2026-01-15

For each station the tool finds the row with the highest temp_c and returns its reading_date. Auckland's failed reading has no temperature, so it is skipped and 26.1 on 14 January wins. The output has one row per station, sorted by station, and the column name is built from the chosen columns because none was typed.

Working with Parquet files

Parquet columns are typed, so the comparison is exact. Timestamps compare at full precision, which makes arg_max(event_id, event_time) a quick way to get the latest event per user. Decimals compare exactly, with no floating-point rounding. Text columns compare by byte order, so uppercase letters sort before lowercase. Boolean columns can be used too, with true counting as higher than false. For a huge file, the whole table is loaded into browser memory first, so very large Parquet files may need a machine with plenty of RAM.

The group column keeps its Parquet type in the preview, and INT64 ids, dates and strings all group correctly. Pick a scalar column to return, such as a string, number or timestamp. The result is downloaded as CSV, and struct or list values do not convert to readable CSV text, so extract the nested field into its own column first. To pull several columns from the winning row, run the tool once per column, or use Top N per Group with N = 1.

Frequently Asked Questions

Can I get the latest record per user from a Parquet file?

Yes. Choose arg_max, find the max of the timestamp column, return the column you need, and group by the user column. Each user gets the value from their most recent row.

Can arg_max return several columns from a Parquet file at once?

Not as separate columns. Return one column per run, or use Top N per Group with N = 1 to keep the entire winning row.

What happens when two rows tie for the maximum?

One of them is returned, and which one is not guaranteed. If ties matter, use Top N per Group or the SQL workspace to see every tied row.

How are NULL values handled?

Rows where either the value column or the returned column is NULL are skipped. If every row in a group is skipped, that group's result is empty.

Can I return the maximum value itself?

Choose the same column in both pickers and arg_max returns the maximum, but the Aggregate tool is the simpler way to get max and min values.

Related Tools