add structure for queries