Splunk Search

Grouping the data row based

rsathish47
Contributor

HI All,

I need to group the data row based my table looks like this.

Table:

DBName Region Dag count

DB1 US DG1 3

DB1 EUR DG1 5

DB2 US DG3 4

DB3 EUR DG2 5

DB3 US DG2 3

DB3 Ap DG2 6

Result Table

DBName Region Dag count

DB1 US,EUR DG1,DG1 3,5

DB2 US DG3 4

DB3 EUR,US,Ap DG2,DB2,DB2 5,6,3

Please let me know if their any workaround

Thanks
Sathish R

Tags (1)
0 Karma

somesoni2
SplunkTrust
SplunkTrust

Similar, but formatted as per your example:

..your base search...| stats delim="," values(Region) as Region values(Dag) as Dag values(count) as count by DBName | nomv Region | nomv Dag | nomv count
0 Karma

adityapavan18
Contributor

Could you try like

| stats values(Region) as Region values(Dag) as Dag values(count) as count by DBName.

you can also use list instead of values.

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