Splunk Search

Splunk: Query not returning all columns

itsmevic
Communicator

Hello,

 For some reason, my search is not returning all of the columns that I'd like to include in my search.  It's returning all of the columns EXCEPT "title" and "department".  Is there a limit to how many fields one can use? AND why would the columns noted not populate once the query is done?

index=* sourcetype=* "my keyword" 
| fields _time, user, src_user, action, EventCodeDescription, title, department
0 Karma

to4kawa
Ultra Champion
| makeresults count=1000
| streamstats count
| transpose 0 header_field=count

1000 fields are all right.

index=* sourcetype=* "my keyword" 
 | fields _time, user, src_user, action, EventCodeDescription, title, department

I think these fields may not be present in the event containing the keyword.

0 Karma

adonio
Ultra Champion

maybe those fields arent in the data when you use your keyword filter?
try to remove it, run the search in verbose and look on the fields on the left hand side, are title and department there?

efavreau
Motivator

Related to adonio's requirement, make sure there's data in the fields, and ask for it before the first pipe. This will only get when all of them have a value. Example:
index=* sourcetype=* "my keyword" user=* src_user=* action=* EventCodeDescription=* title=* department=*

###

If this reply helps you, an upvote would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...