MySQL error
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 'group by a.cod_album order by a.nome' at line 13
In esecuzione:
select *, a.nome as nome from album a join rel_pagine r on r.cod_rif=a.cod_album join rel_immagini ri on ri.cod_rif=a.cod_album join immagini i on ri.cod_immagine=i.cod_immagine where ri.tabella='album' and r.tabella='album' and r.cod_pagina= group by a.cod_album order by a.nome