Manipulated End Time for Resource Calendar
Hi,
Can anyone explain why the below does not work? I get a working result in my query but i still get an invalid time error when updating the SQL for the calendar.
CASE WHEN T0.callType IN (2,6,7,12) THEN
CONVERT(INT,CONCAT(CONVERT(INT,CASE WHEN LEN(T1.StartTime) = 4 THEN LEFT(T1.StartTime,2) ELSE LEFT(T1.StartTime,1) END) + CONVERT(INT,LEFT(T2.U_pmHours,1)),CONVERT(INT,RIGHT(T1.StartTime,2)) + CONVERT(INT,RIGHT(T2.U_pmHours,2)*60/100)))
ELSE T1.EndTime
END AS 'End Time',
I have a value on the BP master data which is an additional time of VARCHAR type. I am converting this value to an integer and adding it to the integer format for the StartTime. For the example above StartTime is 900 and the U_pmHours value is 4.50 (4 and a half hours). The query is giving me the right new EndTime of 1330 but the calendar query is giving me the below error.
Any help is appreciated.
Comments
0 comments
Please sign in to leave a comment.