Hi,
i am using $col["name"] to get table data (call duration in seconds). i trying to use
$col["name"] = "call_duration";
$col["name"] = ceil($col["name"]/60);
function in order to round the the seconds to minutes. but it is not getting records in grid. Thanks.
You can do such conversion in sql query.
e.g.
$g->select_command = "select …. ceil(call_duration/60) as call_duration, … from table";
can we use sql query with $col["name"]. because when i use
$g->select_command = "select ceil(call_duration/60) as call_duration from table";
it does conversion but there are no records in table except call_duration.
You should select all fields that you want to display in sql query.
$g->select_command = "select f1,f2,f3,…..,ceil(call_duration/60) as call_duration from table";