Splunk Search

After joining 2 tables with just the fields I need, how do I store this new table with the "table" command to use in a different search?

preetham2677
Engager

I tried to create a search by joining 2 tables and created a new table with just the fields I need. When I tried to view this table in a new search, the fields from just the first table are populated, but not the joined table field values.

0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust

It would help to see examples of your data, your existing searches, and what you want in the results.

Keep in mind that Splunk is not SQL. In Splunk, a table is a data display format, not an input.

---
If this reply helps you, Karma would be appreciated.

View solution in original post

0 Karma

richgalloway
SplunkTrust
SplunkTrust

It would help to see examples of your data, your existing searches, and what you want in the results.

Keep in mind that Splunk is not SQL. In Splunk, a table is a data display format, not an input.

---
If this reply helps you, Karma would be appreciated.
0 Karma

preetham2677
Engager

Thanks for the reply.

Sample Query for better understanding the scenario:

source="Table1.csv"

| join type=inner Code[search source="Table2.csv" ]
| eval NewField = "October"
| table Table_new Table1field1, Table2field1, NewField

Is there a way I can store "Table_new" so that I can use it a different query? Or is there a different and efficient way to do it.

Thanks in advance!

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Have a look at the outputlookup command, which would replace the table command. It stores the query output in a file which a subsequent query can read using inputlookup.

---
If this reply helps you, Karma would be appreciated.

preetham2677
Engager

Thank you that worked

0 Karma
Get Updates on the Splunk Community!

Enterprise Security Content Update (ESCU) | New Releases

In December, the Splunk Threat Research Team had 1 release of new security content via the Enterprise Security ...

Why am I not seeing the finding in Splunk Enterprise Security Analyst Queue?

(This is the first of a series of 2 blogs). Splunk Enterprise Security is a fantastic tool that offers robust ...

Index This | What are the 12 Days of Splunk-mas?

December 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...