added queries abstraction