why this query doesn't work, im trying to compare the field idlic with an existing user that belongs to that idlic.
the returning message from mysql is an unknown column, how do i save the value for used in a comparison.
select *, (select licencia from cuentas where idcuenta = ht.cuenta) as idlic
from hojastrabajo ht
where idlic = (select licencia from asociadolicencia where usuario = (select idusuario from usuarios where nombre = 'desarrollador' ))