# Dropping characters from a field

**URL:** <https://discuss.elastic.co/t/dropping-characters-from-a-field/93426>\
**Category:** Logstash\
**Created:** [July 17, 2017, 4:08pm UTC](https://discuss.elastic.co/t/dropping-characters-from-a-field/93426 "2017-07-17T16:08:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sentinel](https://avatars.discourse-cdn.com/v4/letter/s/fbc32d/32.png) [@sentinel](https://discuss.elastic.co/u/sentinel)\
**Post date:** [July 17, 2017, 4:08pm UTC](https://discuss.elastic.co/t/dropping-characters-from-a-field/93426/1 "2017-07-17T16:08:37Z")

</div>

I have a field called usp which is mapped to what is supposed to be a URL but due to my kv filters renders it as  
see below  
I want to remove the // using kv.

![](https://us1.discourse-cdn.com/elastic/original/3X/6/8/68a4e59963950b04bf41e28e8347c9e001cc21b3.PNG)

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [July 18, 2017, 2:13pm UTC](https://discuss.elastic.co/t/dropping-characters-from-a-field/93426/2 "2017-07-18T14:13:26Z")

</div>

Use a mutate filter's gsub option.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 15, 2017, 2:13pm UTC](https://discuss.elastic.co/t/dropping-characters-from-a-field/93426/3 "2017-08-15T14:13:45Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
