How can we show the total sum of table along with group by sum. Here is the table
Table Name – Population
City Building_no population
Chicago 5 10
Chicago 6 20
Denver 8 25
Denver 9 30
Output
City City_Population Total_Population
Chicago 30 85
Denver 55 85
I am able to get City_population with below code –
select city, sum(population) from population group by city
How do i get the column of total_population?