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!

Splunk App for Anomaly Detection End of Life Announcment

Q: What is happening to the Splunk App for Anomaly Detection?A: Splunk is officially announcing the ...

Aligning Observability Costs with Business Value: Practical Strategies

 Join us for an engaging Tech Talk on Aligning Observability Costs with Business Value: Practical ...

Mastering Data Pipelines: Unlocking Value with Splunk

 In today's AI-driven world, organizations must balance the challenges of managing the explosion of data with ...