How can I get the number of posts that a user has posted using one MySQL query? 

I can't really think of anything but this, but there is no aggregate function on the join. So I'm not sure how to proceed. I am positive that `joins` will not accomplish what I need.

```
select a1.username as Username
from `logs` as a1
left join `logs` as a2
on a1.username = a2.username

```

For example, my `logs` table is filled with information about posts people have made. I want to find how many posts each user has made, i.e.

```
Username, Posts
User1     100
User2     200

```

etc

EDIT: Sorry for not providing enough information. 

I have a table called `logs` and it has two columns. One column is called `username` and another column is called `msg`. It basically holds information about posts that people have posted.

For example, let's say someone named `Red` posts `Hello world`. It will be saved to the table `logs` and a new row will be created. `username` will be `Red`, and `msg` will be `Hello world`

I basically want to get the number of messages that EVERY SINGLE user has posted by their username. I.e. here is an example of what I want

```
Username Posts
Red 1
Blue 10
Sally 30

```