I'm trying to make a statement that basically says if EDW_ABC.edw_xdpt_act_arrv_lb
is NULL then use EDW_ABC.edw_putt_act_arrv_lb
and if both are null then set the value to 0. How do I do that? I'm trying the below and I know it's not correct.
EDW_ABC = EDW_ABC.withColumn('act_arrv_abc_lbs', F.when(
(EDW_ABC.edw_xdpt_act_arrv_lb.isNull() == True) & (EDW_ABC.edw_putt_act_arrv_lb.isNull() == True). F.lit(0)\
.otherwise(EDW_ABC.edw_xdpt_act_arrv_lb.isNull()), EDW_ABC.edw_putt_act_arrv_lb)