cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper V
Helper V

Vlookup on 3 columns

Hi,

If a part no.  have Lenth, width height (not blank or zero any of the 3 columns) then YES else NO. I need your help.

 

Part noLenthwidthHeightResult
1233305NO
1234 86NO
1235234YES
1236  2NO
1237123YES
1 ACCEPTED SOLUTION

Accepted Solutions
Community Champion
Community Champion

Hello @sbhan4

Your question is unclear, do you have two tables or do you want the calculation in a single table.

My answer was for a table and I misplaced OR instead of y.

Medida: IF(SELECTEDVALUE(table[Length])>0 && SELECTEDVALUE(table[width])>0 && SELECTEDVALUE(table[Height])>0, "YES","NO")

O

Measurement: IF(ISBLANK(SELECTEDVALUE(table[Length]) ISBLANK(SELECTEDVALUE(table[width]) ISBLANK(SELECTEDVALUE(table[Height]) SELECTEDVALUE(table[Length]) ? 0 ? SELECTEDVALUE(table[width]) to 0 ? SELECTEDVALUE(table[Height]) to 0, "NO","YES")


Hope it resolves your issue? Please consider accepting it as the solution to help the other members find it more quickly.


Appreciate your Kudos, Press the thumbs up button!!👍


Regards,
Pranit


View solution in original post

12 REPLIES 12
Community Champion
Community Champion

Hi @sbhan4 

Please make sure your three number columns are of number type.

 

Measure = IF(SELECTEDVALUE(table[Length]>0 || SELECTEDVALUE(table[width]>0 || SELECTEDVALUE(table[Height]>0, "YES","NO")

 

OR

 

Measure = IF(ISBLANK(SELECTEDVALUE(table[Length]) || ISBLANK(SELECTEDVALUE(table[width]) || ISBLANK(SELECTEDVALUE(table[Height]) || SELECTEDVALUE(table[Length] = 0 || SELECTEDVALUE(table[width] = 0 || SELECTEDVALUE(table[Height] = 0, "NO","YES")


Hope it resolves your issue? Please consider accepting it as the solution to help the other members find it more quickly.


Appreciate your Kudos, Press the thumbs up button!!👍


Regards,
Pranit


@pranit828 Thanks. Didn't work for me. Can you provide me pbix file for it?

Community Champion
Community Champion

Hello @sbhan4

Your question is unclear, do you have two tables or do you want the calculation in a single table.

My answer was for a table and I misplaced OR instead of y.

Medida: IF(SELECTEDVALUE(table[Length])>0 && SELECTEDVALUE(table[width])>0 && SELECTEDVALUE(table[Height])>0, "YES","NO")

O

Measurement: IF(ISBLANK(SELECTEDVALUE(table[Length]) ISBLANK(SELECTEDVALUE(table[width]) ISBLANK(SELECTEDVALUE(table[Height]) SELECTEDVALUE(table[Length]) ? 0 ? SELECTEDVALUE(table[width]) to 0 ? SELECTEDVALUE(table[Height]) to 0, "NO","YES")


Hope it resolves your issue? Please consider accepting it as the solution to help the other members find it more quickly.


Appreciate your Kudos, Press the thumbs up button!!👍


Regards,
Pranit


View solution in original post

@sbhan4 

Formula given by @pranit828  works perfectly,

@pranit828  you have missed closing Parthese after each Selected value that is creating problem to him

Just Rewrite the Fucntion and Share

Community Champion
Community Champion

Thank you @VijayP 

I have updated the formula.


Hope it resolves your issue? Please consider accepting it as the solution to help the other members find it more quickly.


Appreciate your Kudos, Press the thumbs up button!!👍


Regards,
Pranit


Continued Contributor
Continued Contributor

@sbhan4 

 

You're looking for an IF statement and not a vlookup..?

 

If so, create a new column

 

Result = IF(OR(OR('Table'[Height]=0,ISBLANK('Table'[Height])),or(OR('Table'[Length]=0,ISBLANK('Table'[Length])),OR('Table'[Width]=0,ISBLANK('Table'[Width])))),"NO","YES")

@VijayP  Thank you, Vijay! I have provided brackets as well but didn't work for me. Can you please try this out in pbix file.

@darentengmfs Vlookup or ef else anything is fine. The REsult should come to like that

Continued Contributor
Continued Contributor

@sbhan4 

 

Please try my formula in the reply above.

Helpful resources

Announcements
November Update

Check it Out!

Click here to read more about the November 2020 Updates!

Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

secondImage

Power Platform October Community Highlights

Check out the top community contributors across all of the communities

secondImage

Create an end-to-end data and analytics solution

Learn how Power BI works with the latest Azure data and analytics innovations at the digital event with Microsoft CEO Satya Nadella.

Top Solution Authors
Top Kudoed Authors