Splunk Search

いくつかのvalueを一つにまとめたい

appleman
Contributor

nameというフィールドに、同じappAという名前が、「app A」、「app a」、「App A」などのようにいくつかvalueの入力方法が異なってしまい、stats countした際に別のものとして認識されてしまいます。
eval case()とかで指定すると、他の正常に入ってきているデータが省かれてしまうので、
他にうまくまとめる方法はございますでしょうか。

Tags (3)
0 Karma
1 Solution

melonman
Motivator

以下、一旦小文字に変換してから count してますが、どうでしょうか。

... | eval yourfield=lower(yourfield) | stats count by yourfield

View solution in original post

0 Karma

melonman
Motivator

以下、一旦小文字に変換してから count してますが、どうでしょうか。

... | eval yourfield=lower(yourfield) | stats count by yourfield
0 Karma

appleman
Contributor

これだけだと、nameの中にあるスペースの有無や、日本語と英語で書かれているものを別のものと認識したままになってしまいます。。。。
(例:日本語でグーグルと入っているものと英語でGoogleと入っているものも名前は一緒なので1つのものとしてカウントさせたいです)

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Wondering How to Build Resiliency in the Cloud?

IT leaders are choosing Splunk Cloud as an ideal cloud transformation platform to drive business resilience,  ...

Updated Data Management and AWS GDI Inventory in Splunk Observability

We’re making some changes to Data Management and Infrastructure Inventory for AWS. The Data Management page, ...