added updateByQuerry util. It still needs work.