Try the following script. It worked for me. Note that "original_table" must be the name of the table on which you perform the query. The detail is the name of the ranges of days ... I had them start with letters to be able to sort them easily.
select COUNT(*) as cantidad_registros, rango_dias
from (
select case
when dias between 0 and 15 then 'a) 0 a 15'
when dias between 16 and 30 then 'b) 16 a 30'
when dias between 31 and 45 then 'c) 31 a 45'
else 'd) mas de 45' end as rango_dias,
dias
from (
select id, titulo, DATEDIFF(day, fecha_ingreso, GETDATE()) as dias
from tabla_original) res) tabla
group by rango_dias order by rango_dias;
I hope I can help you!