Story #1565: Fixed that MySQL statement