puedes usar DATE_ADD() función para agregar días a su fecha actual que se obtiene por NOW() función:
select count(table1.id), max(table2.date) from table1
INNER JOIN table2 ON table1.id = table2.id
group by table2.date
having DATE(table2.date) > DATE_ADD(NOW(), INTERVAL 30 DAY)