I have an index and I wanna create a timelion with a percentage diagram for every month.
(count items where: val>30) / (items where: val<30)
know i have only :
.es(index=rn-da-q-15-es, timefield=final_date, metric=avg:value)
I have an index and I wanna create a timelion with a percentage diagram for every month.
(count items where: val>30) / (items where: val<30)
know i have only :
.es(index=rn-da-q-15-es, timefield=final_date, metric=avg:value)
Hey @Yevhen_Baidiuk,
It looks like the divide function is what you need:
.es(index="rn-da-q-15-es",q="val:[30 TO *]").divide(.es(index="rn-da-q-15-es",q="bytes:[* TO 30]"))
Thanks but i need somehow count of results , not values itself
.es(index="rn-da-q-15-es",q="val:[30 TO *]").count().divide . . . ...
I found :
.es(index='rn-da-q-2-es', timefield='final_date', metric=count:value, q='value:[30 TO *]')
.divide(
.es(index='rn-da-q-2-es', timefield='final_date', metric=count:value)
)
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
© 2020. All Rights Reserved - Elasticsearch
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant logo are trademarks of the Apache Software Foundation in the United States and/or other countries.