Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有以下查询:
SELECT sum("field1" * "field2") FROM "my_db"."autogen"."data" GROUP BY time(1d) FILL(null)
简而言之,我想sum对两个字段的乘积field和field2.
sum
field
field2
上面的查询返回一个错误:expected field argument in sum()。
expected field argument in sum()
这种事情在 InfluxDB 中完全可能吗?
这是一个想法:尝试 Sub Query
注意:我现在没有编辑器,所以它也可能会出错
SELECT SUM(Multiplication) FROM (SELECT "field1" * "field2" as Multiplication, time(1d) as Days FROM "my_db"."autogen"."data" GROUP BY time(1d) FILL(null) ) GROUP BY Days