sql use with to get value counts and percentages

Solutions on MaxInterview for sql use with to get value counts and percentages by the best coders in the world

we are a community of more than 2 million smartest coders
registration for
employee referral programs
are now open
get referred to google, amazon, flipkart and more
register now
  
pinned-register now
showing results for - "sql use with to get value counts and percentages"
Maryam
30 Apr 2018
1SELECT event, 
2       count(event) as event_count,
3       count(event) * 100.0 / (select count(*) from event_information) as event_percent
4FROM event_information
5group by event
6