Splunk Search

csv lookup number vs string

dglass0215
Path Finder

I have a csv lookup that has a column with numerical data (specifically integers).  When I do the lookup, splunk is treating it as string data.  For example if I use this column to sort the numbers 1,2,3,10,11 it sorts as 1,10,11,2,3.

Any help is appreciated.

Labels (1)
0 Karma

isoutamo
SplunkTrust
SplunkTrust
You can do e.g.
eval num = tonumber(field_as_string)
There are also some other ways to do it, which you could found by goole.
r. Ismo
0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...