Let's say we have the following table:
city gender
abc m
abc f
def m
Required output:
city f_count m_count
abc 1 1
def 0 1
Please help me in writing a query either in Hive or MySQL or SQL Server syntax. Hive syntax is needed for me.
Thank You:)