Splunk Search

SPL: Longest common substring

jroedel
Path Finder

Hello everyone,

I am looking for a SPL-solution to determine how long the longest common substring of two strings is.

Is there any built-in way to do that? Or is there any app that provides me with some command for that?

 

Thanks in Advance!

Labels (1)
Tags (2)
0 Karma

PickleRick
SplunkTrust
SplunkTrust

No, there is no built-in command to find that.

You could try to implement it in SPL and that could be an interesting exercise in itself but it would most probably _not_ be a very effective solution.

If you really need that you should probably implement it as an external command using python.

0 Karma

psherman42
Engager

You probably need to use external scripting such as python to solve your algo processing needs as it falls outside simple text pattern matching. By design Splunk itself is more designed for data retrieval, aggregation and general text operations which I would consider the typical use case of Splunk. 



Tags (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

I think you'll need an external command to do that.

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

Automatic Discovery Part 1: What is Automatic Discovery in Splunk Observability Cloud ...

If you’ve ever deployed a new database cluster, spun up a caching layer, or added a load balancer, you know it ...

Real-Time Fraud Detection: How Splunk Dashboards Protect Financial Institutions

Financial fraud isn't slowing down. If anything, it's getting more sophisticated. Account takeovers, credit ...

Splunk + ThousandEyes: Correlate frontend, app, and network data to troubleshoot ...

 Are you tired of troubleshooting delays caused by siloed frontend, application, and network data? We've got a ...