Мне нужно сгенерировать такую строку в хранимой процедуре.
select case when Sex like '%' then 'Person' end as Sex from tableName;
В хранимой процедуре я сгенерировал вот так.
select case when Sex like quote(%) then quote(Person) end as Sex from tableName;
Я получил ошибку
Error Code: 1064. You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '%) then quote(Person) end as Sex from tableName' at line 1 0.000 sec
Моя версия MariaDB '10 .3.16-MariaDB '
Пожалуйста, помогите в решении этой проблемы.