fixes 610
NPE on query entry