# Wildcard with drop\_fields

**URL:** <https://discuss.elastic.co/t/wildcard-with-drop-fields/123237>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [March 9, 2018, 9:49am UTC](https://discuss.elastic.co/t/wildcard-with-drop-fields/123237 "2018-03-09T09:49:02Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![CeeDee](https://avatars.discourse-cdn.com/v4/letter/c/9fc29f/32.png) [@CeeDee](https://discuss.elastic.co/u/CeeDee)\
**Post date:** [March 9, 2018, 9:49am UTC](https://discuss.elastic.co/t/wildcard-with-drop-fields/123237/1 "2018-03-09T09:49:02Z")

</div>

Hi,

I wish to drop multiple fields starting with the same pattern (e.g. postgresql.database.rows.\*) from my metricbeat config.

I've tried the following syntax but it does not seem to work:

```auto
  processors:
  - drop_fields:
      fields: ["postgresql.database.rows.*"]

```

Am I using a wrong syntax or is wildcard with the field names simply not supported at all?

Thank you in advance for your reply.

---

<div class="post-metadata">

**Author:** ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)\
**Post date:** [March 12, 2018, 12:25pm UTC](https://discuss.elastic.co/t/wildcard-with-drop-fields/123237/2 "2018-03-12T12:25:02Z")

</div>

Wildcards are currently not supported. For your case the following could work:

```auto
fields: ["postgresql.database.rows"]

```

It will remove the `rows` object which contains all the other fields. Haven't tested this but I think that should work.

---

<div class="post-metadata">

**Author:** ![CeeDee](https://avatars.discourse-cdn.com/v4/letter/c/9fc29f/32.png) [@CeeDee](https://discuss.elastic.co/u/CeeDee)\
**Post date:** [March 12, 2018, 2:07pm UTC](https://discuss.elastic.co/t/wildcard-with-drop-fields/123237/3 "2018-03-12T14:07:02Z")

</div>

Thanks ruflin, using the syntax you provided did the trick!

---

<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:** [April 9, 2018, 2:07pm UTC](https://discuss.elastic.co/t/wildcard-with-drop-fields/123237/4 "2018-04-09T14:07:13Z")

</div>

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