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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
Anonymous
Not applicable

Custom column with IF and AND statement

Hi, I have 2 columns that look like this

nielsr_0-1604927745063.png

 

Now I want to create a custom column that shows "TRUE" when

ID=68 and

Included = TRUE


How do write this in Power Query?

 

2 ACCEPTED SOLUTIONS
mahoneypat
Employee
Employee

This should work

 

= if [BoatIncludeExcludeId] = 68 and [InFulllEquipmentPackage] = true then true else false

 

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


View solution in original post

Icey
Community Support
Community Support

Hi @Anonymous ,

 

You can also create a custom column like so:

 = if [ID] = 68 and [Included] then true else false

true.JPG

 

 

Best Regards,

Icey

 

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
wdx223_Daniel
Super User
Super User

clike Add Column ---> Custom Column, and input this formula

[BoatIncludeExcludeItemId] = 68 and [Included]

Icey
Community Support
Community Support

Hi @Anonymous ,

 

You can also create a custom column like so:

 = if [ID] = 68 and [Included] then true else false

true.JPG

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

mahoneypat
Employee
Employee

This should work

 

= if [BoatIncludeExcludeId] = 68 and [InFulllEquipmentPackage] = true then true else false

 

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

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

Top Solution Authors
Top Kudoed Authors