ExecuteSQL does not return any value.
I have tables: Tasks(_kp_task_id, status) and Staffs(_kp_staff_id, status). One Staff can work on multi tasks and if the last tasks's status is Delivery that's mean the status of the staff is free.
I design one layout to show all staff and their status base on their last Tasks. But when I write calculation for the staff status column as:
$task_id = Max( Tasks::_kp_task_id);
$status = ExecuteSQL ( "Select Tasks::status from Tasks where Tasks::_kp_task_id = ?" ; "" ; ""; $task_id );
It returns nothing. Please show me the reason why. It is seemly wrong on the ExecuteSQL, Why?