Forum Discussion

Hesham's avatar
Hesham
Frequent Visitor
8 years ago
Solved

update blank Values in formula column

Hello,

 

i am new in Power Bi and need help.....

 

i write a formula to be updated based on two other colunms (Time Columns with format HH:MM) , it worked perfect but the problem it retrun the 00:00 value in the final_time with blank and that make a problem in the charts. any help .....

i need it to return same value "00:00"

 

Final_Time = IF(Source[Day_time]=BLANK(),IF(Source[Day_time2]=BLANK(),Source[Day_time],Source[Day_time2]),IF(Source[Day_time]=BLANK(),Source[Day_time2],Source[Day_time]))

 

 

 

 

 

 

 

 

Best rgards

Hesham

  • You might try using CONCATENATE with a "" when returning values to make your end result column Text, so something like:

     

    IF(Source[Day_time]=BLANK(),
    	IF(Source[Day_time2]=BLANK(),
    		CONCATENATE(Source[Day_time],""),
    		CONCATENATE(Source[Day_time2]),""),
    	IF(Source[Day_time]=BLANK(),
    		CONCATENATE(Source[Day_time2],""),
    		CONCATENATE(Source[Day_time]),"")
    )

2 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Community Champion

    You might try using CONCATENATE with a "" when returning values to make your end result column Text, so something like:

     

    IF(Source[Day_time]=BLANK(),
    	IF(Source[Day_time2]=BLANK(),
    		CONCATENATE(Source[Day_time],""),
    		CONCATENATE(Source[Day_time2]),""),
    	IF(Source[Day_time]=BLANK(),
    		CONCATENATE(Source[Day_time2],""),
    		CONCATENATE(Source[Day_time]),"")
    )
    • Hesham's avatar
      Hesham
      Frequent Visitor

      Many Thanks Smoupre for your efforts, i got the idea and did work around by update it from another dummy table.