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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
vierarc1234
Regular Visitor

criteria var - ID PRODUCT

Hello everybody,
I have an order base and in this a “Product ID” can occur in the 3 situations "In", "Out" or "Both" in a machine.

vierarc1234_1-1682357470769.png
I wanted to create a variable according to the “Criteria Used” table to show in each “Product ID” which class "In", "Out" or "Both" it fits.
Doing it through the Visual Matrix, I can see the manual by different entries, where the entire column refers to the criterion “B” because there has already been an order in condition “I” and “O”.

can anybody help me?
Thank you very much.

 

 

 

 

 

1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi @vierarc1234 

please try

ID Result =
IF (
HASONEVALUE ( 'Table'[Type] ),
IF ( VALUES ( 'Table'[Type] ) = "In Machine", "In", "Out" ),
"Both"
)

View solution in original post

1 REPLY 1
tamerj1
Super User
Super User

Hi @vierarc1234 

please try

ID Result =
IF (
HASONEVALUE ( 'Table'[Type] ),
IF ( VALUES ( 'Table'[Type] ) = "In Machine", "In", "Out" ),
"Both"
)

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.