How can I run aggregateWindow function where fn param can have different value for different field?

Suppose I’m having 5 rows with multiple fields let say volume, open and close. And I want to run aggregateWindow function with every 15m and the final row should have volume value with sum, of all volume open value should be first row value, and close value should be last row value.

I feel it seems difficult to understand but let me know if anyone wants more idea what exactly I’m trying to do?

Your reply will be greatly appreciated :slight_smile:

@pavanvora Flux will return each field in separate tables because InfluxDB returns data group by series, and the field key is part of the series key. There are a few ways you can do accomplish what you’re trying to do that are outlined in this similar thread: InfluxQL to new task FLUX with resample and group