added QueryNotFound Exception and added fire result function