query fail callback