I created a MySQL search query using case
inside it.
The problem is that when returning the value of the column that is of integer type, the value comes with the response blob
.
Here is the SELECT with the result of the query below:
select
max(b.sequencia),
case
when b.sequencia is null then '0'
else max(b.sequencia)
end as Max
from
cad_tramitacao b
where
b.ficha = '187080' and b.arquivo = 'M' and b.incidente = "0";