# Kibana Discover and Visualization screen is not showing correct results for the values provided via filters

**URL:** <https://discuss.elastic.co/t/kibana-discover-and-visualization-screen-is-not-showing-correct-results-for-the-values-provided-via-filters/265806>\
**Category:** Kibana\
**Created:** [March 1, 2021, 1:40pm UTC](https://discuss.elastic.co/t/kibana-discover-and-visualization-screen-is-not-showing-correct-results-for-the-values-provided-via-filters/265806 "2021-03-01T13:40:24Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mohitj252](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mohitj252/32/81348_2.png) [@Mohitj252](https://discuss.elastic.co/u/Mohitj252)\
**Post date:** [March 1, 2021, 1:40pm UTC](https://discuss.elastic.co/t/kibana-discover-and-visualization-screen-is-not-showing-correct-results-for-the-values-provided-via-filters/265806/1 "2021-03-01T13:40:24Z")

</div>

Hi,

I have few queries related to discover page and visualization page. I am trying to explain the different scenarios which I observed.

Scenario 1.  
In the discover screen, there are counter values (counter\_value is a field) having floating point values (for eg 0.5, 10.5, 21.4).

When trying to apply filter with condition " **counter\_value is not 0.04**" (table contains values 0.04), it should not show counter values 0.04 in the result table but it is showing.

Please see attached pictures

 ![discover_0.04_showing](https://us1.discourse-cdn.com/elastic/original/3X/a/b/abcbbed05335e609312c67e6fe4c5bc3b71b75dc.jpeg)

Scenario 2.  
In the discover screen, I added the filter ( **counter\_value is 21.xx** (floating value greater than 1)), in the result nothing is coming PFA screenshot.

 ![discover_21.075_table](https://us1.discourse-cdn.com/elastic/original/3X/d/2/d256ba76e5483884c6c9f5db3110a85b72709e20.png)  
 ![discover_21.075_not_showing](https://us1.discourse-cdn.com/elastic/original/3X/6/7/67776cdf8171d897fadb5df2c2be558f1ad46c30.png)

Scenario 3  
In the Visualization screen, for the **counter\_value is 21.xx** , I can see the value 21 (looks like it round off the value) on the graph. PFA screenshot.

 ![visualization_21.075_roundoff_showing](https://us1.discourse-cdn.com/elastic/original/3X/9/c/9c5df66c9fa9207d00bfaf84f53a963ed40867b6.png)

Summary

1. Regarding visualization page, It will round off all the values, for eg if it is 21.04, then it will round off to 21, and then it will show on the graph. Please correct me if I am wrong.
2. Regarding Discover page, it is not showing results for (counter\_value is x.xx), and it is showing value x.xx in the table for a case where I am mentioning, it should not show that value (counter\_value is not 0.04). Please guide me to understand the exact behaviour of the discover and visualization page or does it is a bug with Kibana?

---

<div class="post-metadata">

**Author:** ![flash1293](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/flash1293/32/41227_2.png) [@flash1293](https://discuss.elastic.co/u/flash1293)\
**Post date:** [March 1, 2021, 2:33pm UTC](https://discuss.elastic.co/t/kibana-discover-and-visualization-screen-is-not-showing-correct-results-for-the-values-provided-via-filters/265806/2 "2021-03-01T14:33:30Z")

</div>

Please check your mapping to confirm, but this sounds like `counter_value` is mapped as an integer field (long, integer, short, byte or unsigned\_long), but actually contains values including a decimal point. Visualizations are based on aggregations, so they just work with the indexed value (which is rounded to the nearest integer), but Discover is looking at the `_source` object (the originally ingested JSON object) which includes the original value including the decimal point. The filter doesn't work though because it is relying on the indexed value again.

To fix this, you need to change the mapping (e.g. by using double for this field) and then re-index your data, so Elasticsearch can build a new index based on the floating point number.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 29, 2021, 2:33pm UTC](https://discuss.elastic.co/t/kibana-discover-and-visualization-screen-is-not-showing-correct-results-for-the-values-provided-via-filters/265806/3 "2021-03-29T14:33:45Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
