Erro: -420 Database Error

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'anna/707074' or = 'aluno/fabiana-do-carmo-aguiar-sant'anna/707074?' at line 5

Statement: select, shorturl.url, shorturl.header, shorturl.relatedid, pages.title, pages.alias
from shorturl
left join pages on = shorturl.relatedid and relatedtabledefid = 28140
(( = 'aluno/fabiana-do-carmo-aguiar-sant'anna/707074' or = 'aluno/fabiana-do-carmo-aguiar-sant'anna/707074?')
or ( like '/aluno/*'))
and shorturl.inactive=0 and shorturl.companyid=1
order by desc