﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
404	MySQL order_by=['?'] throws ProgrammingError	mattycakes@…	Adrian Holovaty	"When attempting to get a list in random order with MySQL as the backend, this error is thrown:

{{{
book_list = books.get_list(slug__ne=kwargs['book'], order_by=['?'])
...
ProgrammingError: (1064, ""You have an error in your SQL syntax near '()' at line 1"")
}}}

I would guess it's a db abstraction issue. MySQL uses ORDER BY RAND() for random ordering, I believe.

Revision 545, MySQL 3.23, Mac OS X.3.9"	defect	closed	Metasystem		normal	fixed	mysql order order_by random		Unreviewed	0	0	0	0	0	0
