class containging querys functions