Hay un error: ERROR: column "celebran" does not exist LINE 25: WHERE n.idnota =celebran ^