Is it possible to convert a string into an int, in Kibana?

I'm trying to create a data table using kibana for a set of data in an index. I'm having a field in my database which is a String, and I have to convert it to an int so that I could use it for the sum aggregation in Kibana metrics.

Is there a way that I can directly convert it through Kibana or should I go with the logstash and do the conversion first?

There's no way to do that conversion in Kibana 4. In Kibana 5 you'll be able to write a Painless scripted field that can do the conversion. That said, scripted fields are generally slower than regular fields and have some limitations, so if you can it's best to massage the data with logstash before indexing.

1 Like

Thank you so much.. :slight_smile: