Add minutes(another column) to time column

Database

Add minutes(another column) to time column

Hi Folks,

I want to add certain amount of minute to a time column. I am trying to implement this using interval.

Sel TIME_COLUMN + INTERVAL ‘45’ MINUTE works fine.

But I want to replace ‘45’ with another column(TIM_MIN) but I am getting error 3707.

Could you guys suggest alternate way to implement.

Regards,

Ajay

2 REPLIES
Teradata Employee

Re: Add minutes(another column) to time column

SELECT TIME_COLUMN + TIM_MIN * INTERVAL '1' MINUTE

Re: Add minutes(another column) to time column

Thanks Fed,I have implemented like below:

T203.OFF_PEAK_STIME +  CAST(T304.MIN_DEPTIM_DELTA AS INTERVAL MINUTE),