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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Irek
Helper II
Helper II

Custom Colum with multiple conditions , Hire and Re hire

Hi, 

 

Need to create conditional column and it is a little bit to complex for me 🙂

 

As in below table. 

I have columns Employee Id, process type, process status and event date, result will be mine new column. 

Goal is to show which employee was hire and re hire if have two or more hires against his ID. 

Hire is when process type is Hire or Contract Employee and Status is Successfully Completed and it first appear in report. 

If same employee have another case with same condition then should be consider as Re hire. 

 

I'm trying to write it but so far without result. 

 

Thanks in advance for help

Marcin

 

 

 

 

 

 

employee_id

business_process_typestatusevent_dateRESULT
1Change JobSuccessfully Completed01.04.2023 
1HireSuccessfully Completed01.02.2021New Hire
1HireSuccessfully Completed01.05.2021Re Hire
2HireCanceled01.05.2021 
2Change JobSuccessfully Completed16.02.2023 
2Contract EmployeeSuccessfully Completed12.03.2023New Hire
2Change JobCanceled12.03.2023 
8HireCanceled12.03.2023 
9Change JobSuccessfully Completed05.09.2023 
2 REPLIES 2
PijushRoy
Super User
Super User

Hi @Irek 

Create a custom column and use similar code as per your requirement
= if [business_process_type] = "Hire" and [status] = "Successfully Completed" then "Hire" else 
if [business_process_type] = "2nd Condition" and [status] = "2nd Condition" then "Hire" else "Re Hire"

Please change the code as per your requirement

If solved, please mark as SOLUTION and give 👍




Did I answer your question? Mark my post as a solution!
Appreciate your Like/Kudos

Proud to be a Super User!





Hi Pijush, 

 

Thank you for your respond, 

Re hire should be only when process type is hire or contract, status is completed but employee have two or more lines with such conditions date is not the oldest. I mean that first hire is hire another one is re hire, 

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors