Write a SQL query to extract specific data from a database, including any necessary joins or aggregations.