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!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...