- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to truncate a field or limit a field value
ethanthomas
Path Finder
07-08-2021
08:02 AM
I have a field called org_name in the data as below
Org_name="davidcareerhome"
Org_name ="Ethanfurniture"
I want to limit the Org_name only for the first three bytes as below
Org_name="dav"
Org_name="Eth"
Can someone help me with this and how to do make this change in props.conf and the regex for the same ?
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

richgalloway

SplunkTrust
07-08-2021
09:44 AM
Use the substr function.
... | eval Org_name=substr(Org_name, 1, 3)
---
If this reply helps you, Karma would be appreciated.
If this reply helps you, Karma would be appreciated.
