title: SQL data retrieval issues
body: <p>I have two table profiles and tenancy_history both are connected through <code>PK_FK</code> relationship.</p>
  <p>In profiles I have columns <code>(profile_id,first_name,last_name,email,phone,city_hometown,created_at,gender,referral_code)</code>
  and in tenancy_history
  <code>(profile_id ,rent)</code></p>
  <p>I have been asked
  Write a query to find the rent generated from each city and also the total of all cities.</p>
  <p>I wrote a code to calculate rent generated by each city but dont know how to get total rent in the same query when you using group by.</p>
  <pre><code>select city_hometown ,sum(rent) as rent_generated_from_each_city from
  profiles as p
  full join 
  tenancy_histories as t
  on p.profile_id = t.profile_id
  group by city_hometown
  </code></pre>