# Extract using regex

**URL:** <https://forum.uipath.com/t/extract-using-regex/557644>\
**Category:** Studio\
**Tags:** workflow-diff, question, studio\
**Created:** [June 26, 2023, 7:57am UTC](https://forum.uipath.com/t/extract-using-regex/557644 "2023-06-26T07:57:20Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![yash.choursia](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/yash.choursia/32/366204_2.png) [@yash.choursia](https://forum.uipath.com/u/yash.choursia)\
**Post date:** [June 26, 2023, 7:57am UTC](https://forum.uipath.com/t/extract-using-regex/557644/1 "2023-06-26T07:57:20Z")

</div>

Hi Team,  
I want to extract the part between a space and comma, like my input would be “January 30, 2023” and the output would be “30”.  
One more example is, input will be “March 2, 2023” and the output will be “2”. Please help

---

<div class="post-metadata">

**Author:** ![Yoichi](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/yoichi/32/523754_2.png) [@Yoichi](https://forum.uipath.com/u/Yoichi)\
**Post date:** [June 26, 2023, 7:59am UTC](https://forum.uipath.com/t/extract-using-regex/557644/2 "2023-06-26T07:59:52Z")

</div>

Hi,

Can you try the following expression?

```
System.Text.RegularExpressions.Regex.Match(yourString,"(?<= )\d+(?=,)").Value

```

Regards,

---

<div class="post-metadata">

**Author:** ![lrtetala](https://avatars.discourse-cdn.com/v4/letter/l/e19b73/32.png) [@lrtetala](https://forum.uipath.com/u/lrtetala)\
**Post date:** [June 26, 2023, 8:00am UTC](https://forum.uipath.com/t/extract-using-regex/557644/3 "2023-06-26T08:00:07Z")

</div>

Hi @yash.choursia  
Try this

![image](https://global.discourse-cdn.com/uipath/original/4X/8/f/a/8fa191fa52ee9b07cc9b104dcd23af2b9eb64819.png)

I hope it will helps!!

---

<div class="post-metadata">

**Author:** ![Parvathy](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/parvathy/32/484539_2.png) [@Parvathy](https://forum.uipath.com/u/Parvathy)\
**Post date:** [June 26, 2023, 8:00am UTC](https://forum.uipath.com/t/extract-using-regex/557644/4 "2023-06-26T08:00:08Z")

</div>

Hi @yash.choursia  
Try using the regex expression:

```auto
(?<=[A-Za-z]\s)\d+

```

 ![image](https://global.discourse-cdn.com/uipath/original/4X/2/f/5/2f5a1d95d40bf799158c86bed74d00246aac1f3e.png)

Hope it helps!!  
Regards,

---

<div class="post-metadata">

**Author:** ![pravallikapaluri](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/pravallikapaluri/32/484755_2.png) [@pravallikapaluri](https://forum.uipath.com/u/pravallikapaluri)\
**Post date:** [June 26, 2023, 8:02am UTC](https://forum.uipath.com/t/extract-using-regex/557644/5 "2023-06-26T08:02:15Z")

</div>

Hi @yash.choursia

 ![image](https://global.discourse-cdn.com/uipath/original/4X/f/6/1/f613a2283c4c67d7102b88e874961ae9aed4d532.png)

Hope it helps!!

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/system/32/182466_2.png) [@system](https://forum.uipath.com/u/system)\
**Post date:** [June 29, 2023, 8:02am UTC](https://forum.uipath.com/t/extract-using-regex/557644/6 "2023-06-29T08:02:26Z")

</div>

Closed on June 29, 2023, 8:02am UTC

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