結果 : sql where clause based on case statement