1👍
All you need to do is to cast your output to boolean.
Your query:
SELECT COALESCE(afiliado::boolean, false), COALESCE(id::boolean, false)
FROM `persona`
LEFT OUTER JOIN `afiliado` ON (`persona`.`id` = `afiliado`.`id`);
Source:stackexchange.com