fixed number queries being to inclusive anf date queries not working at all