select rows where values equal the result of count(*) group by?
You can either nest your select and use a where clause in the outer select:

select keyword 
from (
    select keyword, count(*) as cnt
    from mytable
    group by keyword
) as t
where cnt &lt; 4


or you can use having which essentially is a shorter form of the above:

select keyword
from mytable
group by keyword
having count(*) &lt; 4