# List Files regular expression

**URL:** <https://forum.knime.com/t/list-files-regular-expression/4731>\
**Category:** KNIME Analytics Platform\
**Created:** [July 15, 2016, 4:54pm UTC](https://forum.knime.com/t/list-files-regular-expression/4731 "2016-07-15T16:54:39Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![katemeva](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/k/5f8ce5/32.png) [@katemeva](https://forum.knime.com/u/katemeva)\
**Post date:** [July 15, 2016, 4:54pm UTC](https://forum.knime.com/t/list-files-regular-expression/4731/1 "2016-07-15T16:54:39Z")

</div>

Hi!

I have a folder with several files but I need to recognize only one during a loop, the only identificator is a part of file name which is "puc" the rest is a period and name, I tried to do this with &nbsp; the filter option in the node list files called "regular expresion", I have searched how to put the expression that recognize this name's part and I dont find anything about this, the data table which this read is empty when I type puc &nbsp;in the input field.

how can I type "puc" in the extension/Expressoin filter?&nbsp;I mean, there is some special character before of after?&nbsp;

&nbsp;

Thank you so much.&nbsp;

&nbsp;

---

<div class="post-metadata">

**Author:** ![Iris](https://forum-cdn.knime.com/user_avatar/forum.knime.com/iris/32/14_2.png) [@Iris](https://forum.knime.com/u/Iris)\
**Post date:** [July 18, 2016, 10:49am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/2 "2016-07-18T10:49:33Z")

</div>

Hi,

if you select the wildcard pattern option you can add \* for arbitrary signs.

e.g. \*puc\* gives you all files containing puc anywhere.

Best regards, Iris

---

<div class="post-metadata">

**Author:** ![katemeva](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/k/5f8ce5/32.png) [@katemeva](https://forum.knime.com/u/katemeva)\
**Post date:** [July 19, 2016, 6:46pm UTC](https://forum.knime.com/t/list-files-regular-expression/4731/3 "2016-07-19T18:46:58Z")

</div>

Thank you so much,

now my workflow is Ok.

&nbsp;

Best regards.

---

<div class="post-metadata">

**Author:** ![minntheinaung](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/m/35a633/32.png) [@minntheinaung](https://forum.knime.com/u/minntheinaung)\
**Post date:** [March 17, 2020, 5:03am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/4 "2020-03-17T05:03:39Z")

</div>

Hi Iris,  
What if we want to filter _puc_ or _dat_ as multiple condition?

Thank in advance!

---

<div class="post-metadata">

**Author:** ![HansS](https://forum-cdn.knime.com/user_avatar/forum.knime.com/hanss/32/6979_2.png) [@HansS](https://forum.knime.com/u/HansS)\
**Post date:** [March 17, 2020, 7:18am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/5 "2020-03-17T07:18:34Z")

</div>

Hi @minntheinaung welcome to the KNIME Forum

One way to do is to concat 2 List Files nodes.  
 ![Knipsel](https://forum-cdn.knime.com/uploads/default/original/2X/2/2b6b129eaa91737e5911bbfa836cc6975632cde9.jpeg)  
gr. Hans

---

<div class="post-metadata">

**Author:** ![Iris](https://forum-cdn.knime.com/user_avatar/forum.knime.com/iris/32/14_2.png) [@Iris](https://forum.knime.com/u/Iris)\
**Post date:** [March 17, 2020, 7:30am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/6 "2020-03-17T07:30:19Z")

</div>

You can do or with regex as well.

`.*(pub|dat).*`

---

<div class="post-metadata">

**Author:** ![minntheinaung](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/m/35a633/32.png) [@minntheinaung](https://forum.knime.com/u/minntheinaung)\
**Post date:** [March 17, 2020, 11:00am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/7 "2020-03-17T11:00:17Z")

</div>

Thank you for your suggestion, HansS!

---

<div class="post-metadata">

**Author:** ![minntheinaung](https://forum-cdn.knime.com/letter_avatar_proxy/v4/letter/m/35a633/32.png) [@minntheinaung](https://forum.knime.com/u/minntheinaung)\
**Post date:** [March 17, 2020, 11:05am UTC](https://forum.knime.com/t/list-files-regular-expression/4731/8 "2020-03-17T11:05:02Z")

</div>

Thank you for your reply, Iris. Perfect!

---

<div class="post-metadata">

**Author:** ![system](https://forum-cdn.knime.com/uploads/default/original/1X/ab3ccf34482a0329361734a18199390177204f15.png) [@system](https://forum.knime.com/u/system)\
**Post date:** [June 23, 2023, 8:20pm UTC](https://forum.knime.com/t/list-files-regular-expression/4731/9 "2023-06-23T20:20:57Z")

</div>


