Skip to content

Returns the value of one column associated with the minimum value of another column.

func.min_by(get_column(table, 'name'), get_column(table, 'salary'))
func.min_by(get_column(table, 'name'), get_column(table, 'salary'))
┌─────┐
│ Bob │
└─────┘
MIN_BY(<name>, <salary>)
SELECT MIN_BY(name, salary) FROM employees;
┌─────┐
│ Bob │
└─────┘