declare @startDay smalldatetime ='2013-01-01' ;with cte as( select @startDay as d union all select DATEADD(d,1,d) as d from cte where d<'2019-05-01' ) select * from cte
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml&q