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
manish_tripathi
Frequent Visitor

Add a conditional Column with two conditions

Hi I am a power BI beginner, I want to create a new conditional column in table below so that contracttype "Contract" with days as 1 change to "Per Diem", while rest all remain the same?

 

Input:

ContractType Days

Per Diem5
Contract1
Contract5
Contract4
Contract7
Per Diem1
Per Diem2
Per Diem3
Per Diem4
Contract1
Contract1
Permanent30

 

Expected Output:

 

ContractType Days New Type

Per Diem5Per Diem
Contract1Per Diem
Contract5Contract
Contract4Contract
Contract7Contract
Per Diem1Per Diem
Per Diem2Per Diem
Per Diem3Per Diem
Per Diem4Per Diem
Contract1Per Diem
Contract1Per Diem
Permanent30Permanent
1 ACCEPTED SOLUTION
Shaurya
Memorable Member
Memorable Member

Hi @manish_tripathi,

 

You can use:

 

New Type = IF('Table'[Contract Type]="Contract" && 'Table'[Days]=1, "Per Diem", 'Table'[Contract Type])

 

Works for you? Mark this post as a solution if it does!
Check out this post of mine: Forecast Period - Previous Forecasts 
Spare some time to read: How to Export Telemetry Data from Azure IoT Central into Power BI 

View solution in original post

2 REPLIES 2
Shaurya
Memorable Member
Memorable Member

Hi @manish_tripathi,

 

You can use:

 

New Type = IF('Table'[Contract Type]="Contract" && 'Table'[Days]=1, "Per Diem", 'Table'[Contract Type])

 

Works for you? Mark this post as a solution if it does!
Check out this post of mine: Forecast Period - Previous Forecasts 
Spare some time to read: How to Export Telemetry Data from Azure IoT Central into Power BI 

Thank you

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.