Splunk Search

Macro with a macro-name-argument

SonnyB
Explorer

Can a macro be defined, that takes another string as the name of the macro, which gets ‘eval’ed first based on the eventdata, to yield a set of dynamic arguments, which the hosting-macro finally uses as its real arguments, to transform them and/or derive some result, which can then be fed back into the sourcing eventdata itself as a new-field, which can then be used in the next segment of the original search-pipeline?

0 Karma

woodcock
Esteemed Legend

Yes, you can pass a macroname as an argument to one macro and have the called macro call the passed-in macro.

0 Karma

Ayn
Legend

Care to make that question a bit more readable and possible to follow? 🙂

0 Karma
Get Updates on the Splunk Community!

Take Your Breath Away with Splunk Risk-Based Alerting (RBA)

WATCH NOW!The Splunk Guide to Risk-Based Alerting is here to empower your SOC like never before. Join Haylee ...

Industry Solutions for Supply Chain and OT, Amazon Use Cases, Plus More New Articles ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Enterprise Security Content Update (ESCU) | New Releases

In November, the Splunk Threat Research Team had one release of new security content via the Enterprise ...