Dashboards & Visualizations

Software versioning format

nickhills
Ultra Champion

hello guys,

i am trying to build a view of our software versions that we have deployed across our customer base.
our software versioning follows the version, major, minor format, i.e.
2.0.5

i am trying to apply a range map to a single button on the view, but not only does range map not support decimal values, but these values are not 'valid' decimal numbers since they have two decimal points.

does anyone know of a method to convert 2.0.5 to a number value we can run a calculation against.

logically something like this could work.

eval part1=left(version,3) - [returns 2.0]

part2 = tonumber(part1) * 100 - [returns 200]

part3 = right(version,1) - [returns 5]

part4 = part2 + tonumber(part3) - [returns 205]

this seems like an overly complex method, does anyone have any suggestions on a cleaner way of doing this?
is this even possible?

If my comment helps, please give it a thumbs up!
Tags (1)
1 Solution

_d_
Splunk Employee
Splunk Employee

See if this helps:

<my search> | rex field=version mode=sed "s/\.//g"

This will remove all dots from the field called version and convert it to a number.

Hope this helps.

> please upvote and accept answer if you find it useful - thanks!

View solution in original post

_d_
Splunk Employee
Splunk Employee

See if this helps:

<my search> | rex field=version mode=sed "s/\.//g"

This will remove all dots from the field called version and convert it to a number.

Hope this helps.

> please upvote and accept answer if you find it useful - thanks!

aferone
Builder

This drove me nuts for weeks until I found your solution.  Thank you very much!

0 Karma

nickhills
Ultra Champion

perfect.

i knew there would be a simple answer, i spent so much time trying to convert it to a numeric value, i didn't even think of regex.

If my comment helps, please give it a thumbs up!
0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Design, Compete, Win: Submit Your Best Splunk Dashboards for a .conf26 Pass

Hello Splunkers,  We’re excited to kick off a Splunk Dashboard contest! We know that dashboards are a primary ...

May 2026 Splunk Expert Sessions: Security & Observability

Level Up Your Operations: May 2026 Splunk Expert Sessions Whether you are refining your security posture or ...

Network to App: Observability Unlocked [May & June Series]

In today’s digital landscape, your environment is no longer confined to the data center. It spans complex ...