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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Emir_power
Frequent Visitor

Filter by first letter or character

Hi Everyone,

 

I'm trying to filtering a column by the first two charachter

 

Quantity 97*** = CALCULATE(SUM(Invoices[Quantity]); Invoices[ShipPostalCode]  IN {"97***"})

 

ShipPostalCode

97403

97827

99362

97219

99508

 

How to get just the 97*** ShipPostalCode

 

Any help would be appreciated. Thanks! 🙂

 

Emir

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@Emir_power create a calculated column with the first 2 characters using LEFT and then use that in your query you mentioned above.

 

IN Clause - https://www.sqlbi.com/articles/the-in-operator-in-dax/

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

@Emir_power create a calculated column with the first 2 characters using LEFT and then use that in your query you mentioned above.

 

IN Clause - https://www.sqlbi.com/articles/the-in-operator-in-dax/

Thank you Mnayar 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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