# How can i get the interval and used it into formula

**URL:** <https://discuss.elastic.co/t/how-can-i-get-the-interval-and-used-it-into-formula/367141>\
**Category:** Kibana\
**Created:** [September 26, 2024, 1:22am UTC](https://discuss.elastic.co/t/how-can-i-get-the-interval-and-used-it-into-formula/367141 "2024-09-26T01:22:18Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dreamage](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dreamage/32/137875_2.png) [@dreamage](https://discuss.elastic.co/u/dreamage)\
**Post date:** [September 26, 2024, 1:22am UTC](https://discuss.elastic.co/t/how-can-i-get-the-interval-and-used-it-into-formula/367141/1 "2024-09-26T01:22:18Z")

</div>

Hello, I set a Customize time interval 1min in x axis，but when i select a long time range such as 10 hours, the x axis per value change to 5 mins. i get a wrong y axis value. how can i get the interval and used it into formula, e.g. sum(flow.bytes)\*8/\__interval secs_/1000/1000. B.R.

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/f/a/fad51d0e69b1ce01e60aa7a6b533133cf711e76b.png)

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [September 26, 2024, 1:40am UTC](https://discuss.elastic.co/t/how-can-i-get-the-interval-and-used-it-into-formula/367141/2 "2024-09-26T01:40:17Z")

</div>

Hi @dreamage Welcome to the community.

What Version are you on....

Don't forget the Formula Reference...

 ![Screenshot 2024-09-25 at 6.38.28 PM](https://us1.discourse-cdn.com/elastic/original/3X/4/4/443f19c7356e8f2cb403fc8b483b287573106c4b.png)

example

`count()/(interval()/1000)` for seconds

---

<div class="post-metadata">

**Author:** ![dreamage](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dreamage/32/137875_2.png) [@dreamage](https://discuss.elastic.co/u/dreamage)\
**Post date:** [September 26, 2024, 1:51am UTC](https://discuss.elastic.co/t/how-can-i-get-the-interval-and-used-it-into-formula/367141/3 "2024-09-26T01:51:53Z")

</div>

> [@stephenb](#):
>
> on't forget the Formula Reference..

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/2/d/2d40a2a58c28344429084f17e833c806a1593076.png)

version 7.16.0 ...I will upgrade kibana to the latest version and try it. Thank you.
