I do not understand the data for Event5 but I suspect you could use a number/tally table. (Google this.)The number table below is inline.-- *** Test Data in Comsumable Format ***-- Please provide this in futureCREATE TABLE #t( EventId int NOT NULL ,EventName varchar(20) NOT NULL ,EventStartDate datetime NOT NULL ,EventEndDate datetime NOT NULL ,RepeatCount int NOT NULL ,StartTime varchar(10) NOT NULL ,EndTime varchar(10) NOT NULL);INSERT INTO #tSELECT 1, 'Event1','20141104','20141125', 4, '4:30 PM', '6:30 PM'UNION ALL SELECT 2, 'Event2','20141105','20141112', 2, '3.00 AM', '4.00 AM'UNION ALL SELECT 3, 'Event3','20141101','20141115', 3, '1.00 PM', '2.00 PM'UNION ALL SELECT 4, 'Event4','20141030','20141106', 2, '5.30 PM', '6.30 PM'UNION ALL SELECT 5, 'Event5','20141016','20141116', 0, '5.30 PM', '6.30 PM';-- *** End Test Data ***DECLARE @Now datetime;SET @Now = '20141104 15:40';WITH N1(N)AS ( SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1 UNION ALL SELECT 1), N2(N) AS (SELECT 1 FROM N1 A, N1 B), N(N) AS (SELECT ROW_NUMBER() OVER (ORDER BY (SELECT NULL)) - 1 FROM N2), AllEventsAS( SELECT EventId, EventName ,DATEADD(week, N.N, EventStartDate) + REPLACE(StartTime, '.', ':') AS EventStart ,DATEADD(week, N.N, EventStartDate) + REPLACE(EndTime, '.', ':') AS EventEnd FROM #t T JOIN N -- RepeatCount does not make sense for Event5 --ON T.RepeatCount >= N.N ON DATEDIFF(wk, EventStartDate, EventEndDate) + 1 >= N.N)SELECT ROW_NUMBER() OVER (ORDER BY EventStart) AS SNo ,EventId, EventName ,DATEADD(day, DATEDIFF(day, 0, EventStart), 0) As EventDateFROM AllEventsWHERE EventStart <= DATEADD(week, 2, @Now) AND EventEnd >= @Now;