Comment 2 for bug 1077013

Revision history for this message
Gregor Anželj (gregor-anzelj) wrote : Re: Accessing profile pictures report a nonrecoverable eror

The problem is when Mahara database uses prefix for the tables. If there is no prefix, there is no problem...

The SQL that causes the problems can be found in {mahararoot}/artefact/file/profileicons.json.php.
The problems are in lines 35 and 36 which are:

LEFT OUTER JOIN view_artefact va ON va.artefact = a.id
LEFT OUTER JOIN artefact_attachment aa ON aa.attachment = a.id

but should be (notice the curly brackets around table names!):

LEFT OUTER JOIN {view_artefact} va ON va.artefact = a.id
LEFT OUTER JOIN {artefact_attachment} aa ON aa.attachment = a.id