bugfix query