fixes for query reindex/delete.