Skip to main content
Admissions guidance, study banks, and career tools โ€” get started on Shalyam

Users per Email Domain

Count how many users belong to each email domain (the part after '@'). Return domain and user_count, ordered by user_count descending then domain.

Table schema

Users(id INT PRIMARY KEY, email VARCHAR(100))

Sample data

id | email
1 | john@gmail.com
2 | sara@yahoo.com
3 | mike@gmail.com

Discussion

No discussions yet.

Rewards ยท v2.1

Join Shalyam Newsletter

Get exclusive insights with every issue: education, research and innovation news.

One email a week. Unsubscribe any time.