MySQL error in ORDER BY clause in get_artefactchooser_artefacts()
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mahara |
Fix Released
|
Low
|
Yuliya Bozhko | ||
1.10 |
Fix Released
|
Medium
|
Unassigned | ||
1.9 |
Fix Released
|
Medium
|
Unassigned |
Bug Description
For some reason works fine on Postgres...
To reproduce:
1. Create a journal post.
2. Go to pages.
3. Create a page.
4. Add "Journal entry" block.
5. See this error:
Failed to get a recordset: mysqli error: [1064: 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 'BY parent ASC, ctime DESC LIMIT 10' at line 15] in EXECUTE("SELECT a.*, (a.owner IS NOT NULL AND a.owner = '1') AS editable FROM "mhr_artefact" a WHERE ( a.owner = '1' OR a.id IN ( SELECT id FROM "mhr_artefact" WHERE (path = '/5' OR path LIKE '/5/%') AND institution = 'mahara' ) OR a.id IN ( SELECT aar.artefact FROM "mhr_group_member" m JOIN "mhr_artefact" aa ON m.group = aa.group JOIN "mhr_artefact_
SQL is missing space before ORDER BY...
Changed in mahara: | |
importance: | Undecided → Low |
Changed in mahara: | |
milestone: | none → 15.04.0 |
status: | New → Fix Committed |
Changed in mahara: | |
status: | Fix Committed → Fix Released |
Patch for "master" branch: https:/ /reviews. mahara. org/4236