[Solved] How to SUM Datetime per column


AS some of your logstep_* columns value is NULL so try like this with ifnull, I’ve added only three columns you can try with all of your columns. Hope this will help you.

select SEC_TO_TIME(
  UNIX_TIMESTAMP(ifnull(logstep_1, 0)) + 
  UNIX_TIMESTAMP(ifnull(logstep_2, 0)) + 
  UNIX_TIMESTAMP(ifnull(logstep_3, 0))
) as logstep_sum_in_time
from log_step

2

solved How to SUM Datetime per column