Probably i think you want to retrieve the ANI's where calls have count of 30, the below query will take the distinct ANI's and the Count they hit in the Route Call Detail Table.
SELECT DISTINCT (ANI), count(*) AS count
FROM Route_Call_Detail where DateTime
between '' and '' GROUP BY ANI
Check whether this helps.
Regards,
Senthil