30 minute window from date time field

Tools

30 minute window from date time field

Hi

I have a date time field with values like "1/1/2014 01:52:23" , i need to count the number of records with a condition of flag = y , within 30minutes window of this date time column.

So basically if the flag = y within 30 minutes window count that record if not ignore .. \

Please help!