query for inquiries