09-08-13, 12:13 AM
VB6DAO كتب :Select emplo_id, Format((Sum(total_hours)*1440)\60 ,'0') + ':' + Format((((Sum(total_hours)*1440)/60)-((Sum(total_hours)*1440)\60))*60,'0') As Total_Hours From tbl1 Group By emplo_id
تم عمل الكود التالى ولكنه يعطى خطأ ؟
كود :
Select emplo_id, Format((Sum(all_day_hours) * 1440) / 60 ,'0') + ':' +
Format((((Sum(all_day_hours)*1440) / 60) - ((Sum(all_day_hours)*1440) / 60))*60,'0')
As Total_Hours From day_off Group By emplo_idرسالة الخطأ
إقتباس :Msg 8117, Level 16, State 1, Line 1
Operand data type nvarchar is invalid for sum operator.
؟؟؟؟؟؟؟
