Kibana recognizes float as text


#1

i am having an issue with kibana. i am passing converted CSV columns (to float)

57596,48902.348,-0.000130048,34.219,0.000103750,0.001412,6

from logstash using this:

csv{
  separator => ","
  columns => ["col1","col2","col3","col4","col5","col6","col7"]
}

  mutate {convert => [col1, "float"]}
  mutate {convert => [col2, "float"]}
  mutate {convert => [col3, "float"]}
  mutate {convert => [col4, "float"]}
  mutate {convert => [col5, "float"]}
  mutate {convert => [col6, "float"]}
  mutate {convert => [col7, "float"]}

grok {
}

}

the columns in _source are converted

col1:57596col2:48902.348col3:-0.000130048**col4:34.219col5:0.00010375col6:0.001412col7:**6

but kibana displays everything as 't' in the available fields selection area. I can not use the data in a diagram because it is only text.

Any Help is welcome.


(Joe Fleming) #2

Kibana should just be reading the mapping from your index, so I suspect that the values aren't being indexed as floats as you expect.

Hit http://localhost:9200/<YOUR INDEX>/_mappings and check the type value for the field you're looking at. It's probably "text".


#3

Hello and thanks for your reply.

I can tell just by looking at the webinterface that kibana thinks it's a text. How do i get kibana to except as float?

Regards

Rodrick

update:

after checking the _mappings I found out that the fields are declaired as string in one instance. So I generated a new float field then restarted logstash. this generated a field type double. this is displayed as "?" in kibana.

ergo the fields are still not useable.

regards

Rodrick


(Joe Fleming) #4

I believe that the "?" means that Kibana found a field it didn't know about. Did you refresh your field mappings after you added that new field? You can do so in the settings page by selecting the index pattern and clicking the refresh button:


#5

Thanks!!!

That was helpful and it solved my problem.

Have a great weekend.


#6

That worked. Thanks.


(system) #7