added second possibility to do deleteQuery