---
title: into_values() | Tiger Data Docs
description: Returns the lowest values from a MinN aggregate
---

Since [1.16.0](https://github.com/timescale/timescaledb-toolkit/releases/tag/1.16.0)

Return the N lowest values seen by the aggregate.

## Samples

Find the bottom 5 values from `i * 13 % 10007` for i = 1 to 10000.

```
SELECT toolkit_experimental.into_values(
    toolkit_experimental.min_n(sub.val, 5))
FROM (
  SELECT (i * 13) % 10007 AS val
  FROM generate_series(1,10000) as i
) sub;
```

Output:

```
into_values
---------------------------------
1
2
3
4
5
```

## Arguments

The syntax is:

```
into_values (
    agg MinN
) SETOF BIGINT | SETOF DOUBLE PRECISION | SETOF TIMESTAMPTZ
```

| Name  | Type | Default | Required | Description                                                                                                      |
| ----- | ---- | ------- | -------- | ---------------------------------------------------------------------------------------------------------------- |
| `agg` | MinN | -       | ✔        | The aggregate to return the results from. Note that the exact type here varies based on the type of data stored. |

## Returns

| Column       | Type                                                        | Description                                           |
| ------------ | ----------------------------------------------------------- | ----------------------------------------------------- |
| into\_values | SETOF BIGINT \| SETOF DOUBLE PRECISION \| SETOF TIMESTAMPTZ | The lowest values seen while creating this aggregate. |
