Hello, I have problem with grid filtering when using query SELECT CASE
[code]$sql = SELECT id, name,
CASE level
WHEN 0 THEN ‘Level A’
WHEN 1 THEN ‘Level B’
WHEN 2 THEN ‘Level C’
WHEN 3 THEN ‘Level D’
ELSE ‘Level Unknown’
END as case_level
FROM tbl_master
$griddata->render_sql($sql, ‘id’, ‘name,case_level’);[/code]
myGrid.setHeader('Name,Level');
myGrid.attachHeader('#connector_text_filter,#connector_text_filter');
When grid loading for the first time data loading OK,
When type (filtering) at myGrid header col1 OK
but
When type (filtering) at myGrid header col2 got error
Unknown column ‘case_level’ in ‘where clause’
How to fix this problem.
Thanks