Splunk Search

Display data

palisetty
Communicator

How would I display the following data which is part of CSV file? I am looking for a command to do that. top is not working, I can't think of other commands to display
Code Description
200 Success
503 Service unavailable
406 Not Acceptable Client
400 Bad Request Error
408 Request Timeout
500 Internal Server Error
404 Page Not Found
505
403

I want blank values for 505 and 403 to be displayed so that I can try fillnull command.

Tags (1)
0 Karma

woodcock
Esteemed Legend

Like this?

| inputlookup YourLookupFileNameHere.csv
| stats values(*) AS * BY Code Description
| fillnull Description value="UNKNOWN"
0 Karma

gcusello
SplunkTrust
SplunkTrust

Hi @palisetty,
thanks you for your estimate!

Anyway the solution is the one hinted by @vnravikumar: if you already have loaded your csv in a lookup (called e.g. ws_codes.csv) you can use it in three ways using two commands inputlookup and lookup:

If instead you still haven't loaded the csv in the lookup you have to follow two ways:

  • Use Lookup Editor app (the easiest!);
  • create a new lookup in [Settings -- Lookups -- Lookup table files-- Add new].

In both cases, remember to create a Lookup Definition [Settings -- Lookups -- Lookup definition -- Add new].

Ciao and Happy New Year.
Giuseppe

palisetty
Communicator

@gcusello Actually, I didn't want to use lookup.
I am so stupid but later figured it how simple it is.
Just upload the file as I am an Administrator on my machine. Then use head or table commands. then use fillnull value=whatevervalue.

Thank you again. Hope you had a wonderful Christmas

0 Karma

to4kawa
Ultra Champion

If you are looking for answers to the exam, ask such questions.
You mentioned in the video, right?

Transforming command

palisetty
Communicator

Ravi, they are not part of lookup. any simple commands would do? I will try to display from lookup too

0 Karma

vnravikumar
Champion

Hi

Whether that file is part of lookup, if so try with inputlookup or lookup commands

palisetty
Communicator

@gcusello any help please

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Automating Threat Operations and Threat Hunting with Recorded Future

    Automating Threat Operations and Threat Hunting with Recorded Future June 29, 2026 | Register   Is your ...

Keep the Learning Going with the New Best of .conf Hub

Hello Splunkers, With .conf26 getting closer, there’s already a lot of excitement building around this year’s ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...