You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/07/24 07:03:20 UTC
[GitHub] [incubator-druid] ighack opened a new issue #8147: I don't
understand {"name": "latencyMs", "type": "doubleSum",
"fieldName": "latencyMs"}
ighack opened a new issue #8147: I don't understand {"name": "latencyMs", "type": "doubleSum", "fieldName": "latencyMs"}
URL: https://github.com/apache/incubator-druid/issues/8147
I need
select avg(latencyMs),min(latencyMs),sum(latencyMs) from mytable
so make config
I can only do that
"metricsSpec": [
{"name": "views", "type": "count"},
{"name": "latencyMs", "type": "doubleSum", "fieldName": "latencyMs"}
]
or
I should do this
"metricsSpec": [
{"name": "views", "type": "count"},
{"name": "latencyMs", "type": "doubleSum", "fieldName": "latencyMs"},
{"name": "latencyMs", "type": "doubleMin", "fieldName": "latencyMs"},
]
and what about avg?
"metricsSpec": [
{"name": "rows", "type": "count"},
{"name": "latencyMs_SUM", "type": "doubleSum", "fieldName": "latencyMs"},
{"name": "latencyMs_MIN", "type": "doubleMin", "fieldName": "latencyMs"},
],
"aggregations" : [{
{"type" : "count", "name" : "rows"},
{"type" : "doubleSum", "name" : "latencyMs_SUM", "fieldName" : "latencyMs_SUM"}
}],
"postAggregations" : [{
"type" : "arithmetic",
"name" : "latencyMs_AVG",
"fn" : "/",
"fields" : [
{ "type" : "fieldAccess", "fieldName" : "latencyMs_SUM" },
{ "type" : "fieldAccess", "name" : "rows", "fieldName" : "rows" }
]
}]
is that right?
why do I use aggregations?
If I don't make aggregations,can I also "select avg(latencyMs),min(latencyMs),sum(latencyMs) from mytable"
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org