Hmm, going to have to look into this a bit more. The query works on all of the 4.1+, 5.x MySQL installs that I just tested with (about 6 wink ), but failed in the two that are running 4.0.x