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!

Congratulations to the 2025-2026 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Community Feedback

We Want to Hear from You! Share Your Feedback on the Splunk Community   The Splunk Community is built for you ...

Manual Instrumentation with Splunk Observability Cloud: Implementing the ...

In our observability journey so far, we've built comprehensive instrumentation for our Worms in Space ...