queries realized with relationships