cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
muhie New Member
New Member

Like function

Hi there 

 

Please can someone help me with my statement. Im using a like but im getting an error on my like 

Below is my statement 

 

 

if [strSerialNumber] like '%ZF%' then [Line Total Incl]*[ZF Split]/100 else [Line Total Incl] * [All Split]\100 

 

Thanks 

Muhie 

1 ACCEPTED SOLUTION

Accepted Solutions
Moderator v-qiuyu-msft
Moderator

Re: Like function

Hi @muhie,

 

Assume you want to use DAX, you can create a calculated column like below: 

 

Column 2 = IF(SEARCH("ZF",Table1[strSerialNumber] ,1,0),Table1[Line Total Incl]*Table1[ZF Split]/100,Table1[Line Total Incl]*Table1[All Split]/100)

 

q1.PNG


Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
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

1 REPLY 1
Moderator v-qiuyu-msft
Moderator

Re: Like function

Hi @muhie,

 

Assume you want to use DAX, you can create a calculated column like below: 

 

Column 2 = IF(SEARCH("ZF",Table1[strSerialNumber] ,1,0),Table1[Line Total Incl]*Table1[ZF Split]/100,Table1[Line Total Incl]*Table1[All Split]/100)

 

q1.PNG


Best Regards,
Qiuyun Yu

Community Support Team _ Qiuyun Yu
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

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 512 members 4,271 guests
Please welcome our newest community members: