Splunk Enterprise

How to I save my search query output as a lookup ?

zacksoft
Contributor

my search ...
| stats values(something) as nothing
|  outputlookup gemini

I wish my query output to be saved in this outlook .
But when I run the above I get error "The Lookup table gemini is invalid".
I think it is asking for lookup definition .. But How do I provide the definition ..when the lookup file is the output of my query ?

Labels (1)
0 Karma
1 Solution

ashajambagi
Communicator

Hi @zacksoft 

You need to add .csv at the end of the file name i.e gemini.csv

View solution in original post

0 Karma

inventsekar
Ultra Champion

actually, both "outputlook lookupname" and "outputlook lookupname.csv" works fine. just now i tested it as well.  

the documentation says filename must end with .csv or .csv.gz

https://docs.splunk.com/Documentation/Splunk/8.0.6/SearchReference/Outputlookup#Examples

but, without csv, it works fine. Last whole week i have this confusion. 

on the first example, the documentation also gives the filename without ".csv" extension, but it was referring filename from transform.conf. 

EDIT <submitted feedback for this documentation page>

0 Karma

ashajambagi
Communicator

Hi @zacksoft 

You need to add .csv at the end of the file name i.e gemini.csv

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 ...