Add addCount, addFirst, addMax, and addMin functions

Signed-off-by: David Arendsen <darendsen@gamepoint.com>
This commit is contained in:
David Arendsen 2023-02-12 17:18:23 +01:00
commit fc99922700
15 changed files with 463 additions and 23 deletions

View file

@ -0,0 +1,39 @@
# Flux Query Builder Docs
## Functions &raquo; addCount()
### Parameters:
<table>
<tbody>
<tr>
<th>Name</th>
<th>Required</th>
<th>Data type</th>
<th>Description</th>
</tr>
<tr>
<td>column</td>
<td>No</td>
<td>string</td>
<td>Column to count values in and store the total count.</td>
</tr>
</tbody>
</table>
### Example
```php
->addCount("_value")
```
This will result in the following Flux function part:
```
|> count(column: "_value")
```
### Extra resources
* [Flux documentation](https://docs.influxdata.com/flux/v0.x/stdlib/universe/count/)

View file

@ -0,0 +1,39 @@
# Flux Query Builder Docs
## Functions &raquo; addFirst()
### Parameters:
<table>
<tbody>
<tr>
<th>Name</th>
<th>Required</th>
<th>Data type</th>
<th>Description</th>
</tr>
<tr>
<td>column</td>
<td>No</td>
<td>string</td>
<td>Column to operate on. Default is '_value'.</td>
</tr>
</tbody>
</table>
### Example
```php
->addFirst("_value")
```
This will result in the following Flux function part:
```
|> first(column: "_value")
```
### Extra resources
* [Flux documentation](https://docs.influxdata.com/flux/v0.x/stdlib/universe/first/)

39
docs/functions/addMax.md Normal file
View file

@ -0,0 +1,39 @@
# Flux Query Builder Docs
## Functions &raquo; addMax()
### Parameters:
<table>
<tbody>
<tr>
<th>Name</th>
<th>Required</th>
<th>Data type</th>
<th>Description</th>
</tr>
<tr>
<td>column</td>
<td>No</td>
<td>string</td>
<td>Column to return maximum values from. Default is '_value'.</td>
</tr>
</tbody>
</table>
### Example
```php
->addMax("_value")
```
This will result in the following Flux function part:
```
|> max(column: "_value")
```
### Extra resources
* [Flux documentation](https://docs.influxdata.com/flux/v0.x/stdlib/universe/max/)

39
docs/functions/addMin.md Normal file
View file

@ -0,0 +1,39 @@
# Flux Query Builder Docs
## Functions &raquo; addMin()
### Parameters:
<table>
<tbody>
<tr>
<th>Name</th>
<th>Required</th>
<th>Data type</th>
<th>Description</th>
</tr>
<tr>
<td>column</td>
<td>No</td>
<td>string</td>
<td>Column to return minimum values from. Default is '_value'.</td>
</tr>
</tbody>
</table>
### Example
```php
->addMin("_value")
```
This will result in the following Flux function part:
```
|> min(column: "_value")
```
### Extra resources
* [Flux documentation](https://docs.influxdata.com/flux/v0.x/stdlib/universe/min/)