SELECT  
 SUM( 1 ) AS `all`,
 SUM( IF( `role` = 'admin', 1, 0 ) ) AS `admin`,
 SUM( IF( `role` = 'agent', 1, 0 ) ) AS `agent`,
 SUM( IF( `role` = 'client', 1, 0 ) ) AS `client`,
 SUM( IF( `role` = 'guest', 1, 0 ) ) AS `guest` 
 
FROM 
 `user`
 
WHERE
 NOT( ( `username` IS NULL ) OR ( `username` = '' ) )  