[TD-4555] <docs>: update example code about SQL function DERIVATIVE().
This commit is contained in:
parent
d4acd45407
commit
d0c6f75f15
|
@ -1287,15 +1287,15 @@ TDengine支持针对数据的聚合查询。提供支持的聚合和选择函数
|
|||
|
||||
示例:
|
||||
```mysql
|
||||
taos> select derivative(current, 1d, 0) from t1;
|
||||
ts | derivative(current, 1d, 0) |
|
||||
=======================================================
|
||||
2021-08-20 09:18:44.032 | 119.999966667 |
|
||||
2021-08-20 10:18:44.032 | -48.000000000 |
|
||||
2021-08-20 11:18:44.032 | -48.000000000 |
|
||||
2021-08-20 12:18:44.033 | 215.999940000 |
|
||||
2021-08-20 13:18:44.034 | -167.999953333 |
|
||||
Query OK, 5 row(s) in set (0.004772s)
|
||||
taos> select derivative(current, 10m, 0) from t1;
|
||||
ts | derivative(current, 10m, 0) |
|
||||
========================================================
|
||||
2021-08-20 10:11:22.790 | 0.500000000 |
|
||||
2021-08-20 11:11:22.791 | 0.166666620 |
|
||||
2021-08-20 12:11:22.791 | 0.000000000 |
|
||||
2021-08-20 13:11:22.792 | 0.166666620 |
|
||||
2021-08-20 14:11:22.792 | -0.666666667 |
|
||||
Query OK, 5 row(s) in set (0.004883s)
|
||||
```
|
||||
|
||||
- **SPREAD**
|
||||
|
|
Loading…
Reference in New Issue