Splunk Search

Decimal places format

katalinali
Path Finder

Hi all,

I have some statistical log like:
Unit Type (M) Used Rqs Size (K) Rqs Rqs

 1  4326    35165  63.4     .1       5.8     .0     .1
 2  4326    35165  63.4     .2       9.8     .1     .1
 3  4326    17582  77.4     .1       6.3     .0     .1
 4  4326    35165  63.4     .2       8.5     .0     .1
 5  4326    17582  77.4     .1       5.1     .0     .1
 6  4326    35165  63.4     .2       8.1     .0     .2

I used multikv to extract it as field & value pair, but I find ".1", ".2", ".0" is analysed as string instead of numeric, Is there any way that splunk is analysed as numeric. It's better if it can do so when splunk index the data. Thanks.

Tags (1)
0 Karma

Ayn
Legend

Use convert. It is used for this very purpose, converting field values into numerical values.

<yoursearch> | convert auto(<yourfield>)

More information on the convert command is available here: http://docs.splunk.com/Documentation/Splunk/4.2.2/SearchReference/Convert

Ayn
Legend

So, to get this straight - do you have a field with the value ".1" in it, but it's not treated as a numerical field?

0 Karma

katalinali
Path Finder

I have tested "| convert auto(field)", but it doesn't work.

Are there other recommendation. Thanks.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...