CREATE TABLE PersonFriend (name VARCHAR, friend VARCHAR, year INT)
CREATE TABLE Person (name VARCHAR, age INT, city TEXT, gender TEXT, job TEXT)

Return a histogram on how old is each gender, on average?, rank from high to low by the gender.
SELECT gender, AVG(age) FROM Person GROUP BY gender ORDER BY gender DESC
SELECT "gender", AVG("age") FROM "Person" GROUP BY "gender" ORDER BY "gender" DESC NULLS LAST