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

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!

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