Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
AnetaK
Helper V
Helper V

DAX equivalent of SQL LIKE [0-9] [a-z]

Hello,

 

I have a string column with values like:

jkasdjadsj (sdsa) (111)

adkhsjd (343)

FDADasas (asda) (323)

 

I want to extract the "letter part" to have:

jkasdjadsj (sdsa)

adkhsjd

FDADasas (asda)

 

In SQL I would find the position of the bracket that is followed by a numeric character LIKE "([0-9]%"

What can I do in DAX? How to differ those brackets?

 

1 ACCEPTED SOLUTION

Hi @AnetaK,

 

I found this blog written about how to keep only numbers or text might be helpful to you.

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yulgu-msft
Employee
Employee

Hi @AnetaK,

 

If all values in this column are formatted like "xxxxxxx (111)", you could try below DAX formula to create a calculated column:

Column3 = SUBSTITUTE(Sheet2[Column1],RIGHT(Sheet2[Column1],5),"")

1.PNG

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

This is how it lookes like.

 

Przechwytywanie.PNG

 

 

 

Hi @AnetaK,

 

I found this blog written about how to keep only numbers or text might be helpful to you.

 

Best regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.