added additional before/after query methods