<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: SQL Puzzle: Get the list of Monday of a Month	</title>
	<atom:link href="https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/</link>
	<description>BIGData &#124; NoSQL &#124; MSSQL &#124; MySQL &#124; PostgreSQL</description>
	<lastBuildDate>Sun, 27 Oct 2019 14:17:34 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.4</generator>
	<item>
		<title>
		By: Keith Fernandes		</title>
		<link>https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/#comment-7851</link>

		<dc:creator><![CDATA[Keith Fernandes]]></dc:creator>
		<pubDate>Sun, 27 Oct 2019 14:17:34 +0000</pubDate>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=7524#comment-7851</guid>

					<description><![CDATA[declare @start date = &#039;2018-04-01&#039;
declare @end date = &#039;2018-04-30&#039;
;with cte as
(
select @start as date
union all
select DATEADD(DAY,1,date) as date1 from cte
where DATEADD(DAY,1,date) &#060;= @end
)
select * from cte where DATENAME(DW,date) = &#039;Monday&#039;]]></description>
			<content:encoded><![CDATA[<p>declare @start date = &#8216;2018-04-01&#8217;<br />
declare @end date = &#8216;2018-04-30&#8217;<br />
;with cte as<br />
(<br />
select @start as date<br />
union all<br />
select DATEADD(DAY,1,date) as date1 from cte<br />
where DATEADD(DAY,1,date) &lt;= @end<br />
)<br />
select * from cte where DATENAME(DW,date) = &#039;Monday&#039;</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: HIC		</title>
		<link>https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/#comment-7044</link>

		<dc:creator><![CDATA[HIC]]></dc:creator>
		<pubDate>Sat, 27 Apr 2019 13:48:54 +0000</pubDate>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=7524#comment-7044</guid>

					<description><![CDATA[WITH days(mon) AS (
SELECT next_day(to_date(&#039;31.03.2018&#039;, &#039;dd.mm.yyyy&#039;), &#039;monday&#039;) as mon from dual
UNION ALL
SELECT mon + 7 FROM days
WHERE mon + 7 &#060;= to_date(&#039;01.05.2018&#039;, &#039;dd.mm.yyyy&#039;)
)
SELECT * FROM days;]]></description>
			<content:encoded><![CDATA[<p>WITH days(mon) AS (<br />
SELECT next_day(to_date(&#8216;31.03.2018&#8217;, &#8216;dd.mm.yyyy&#8217;), &#8216;monday&#8217;) as mon from dual<br />
UNION ALL<br />
SELECT mon + 7 FROM days<br />
WHERE mon + 7 &lt;= to_date(&#039;01.05.2018&#039;, &#039;dd.mm.yyyy&#039;)<br />
)<br />
SELECT * FROM days;</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Dpan		</title>
		<link>https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/#comment-6980</link>

		<dc:creator><![CDATA[Dpan]]></dc:creator>
		<pubDate>Mon, 15 Apr 2019 09:27:26 +0000</pubDate>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=7524#comment-6980</guid>

					<description><![CDATA[declare @dateOfApril date,@dayOfApril nvarchar(max)
set @dateOfApril=&#039;2018-04-01&#039;;
While (@dateOfApril&#060;&#039;2018-05-01&#039;)
begin
set @dayOfApril=DATENAME(dw,@dateOfApril)
if(@dayOfApril=&#039;Monday&#039;)
Begin
   print @dateOfApril;
End
set @dateOfApril=DateAdd(dd,1,@dateOfApril);
end]]></description>
			<content:encoded><![CDATA[<p>declare @dateOfApril date,@dayOfApril nvarchar(max)<br />
set @dateOfApril=&#8217;2018-04-01&#8242;;<br />
While (@dateOfApril&lt;&#039;2018-05-01&#039;)<br />
begin<br />
set @dayOfApril=DATENAME(dw,@dateOfApril)<br />
if(@dayOfApril=&#039;Monday&#039;)<br />
Begin<br />
   print @dateOfApril;<br />
End<br />
set @dateOfApril=DateAdd(dd,1,@dateOfApril);<br />
end</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: VINUTNA		</title>
		<link>https://www.dbrnd.com/2018/05/sql-puzzle-get-the-list-of-monday-of-a-month/#comment-6419</link>

		<dc:creator><![CDATA[VINUTNA]]></dc:creator>
		<pubDate>Sun, 06 May 2018 14:47:39 +0000</pubDate>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=7524#comment-6419</guid>

					<description><![CDATA[declare @x date = &#039;04-01-2018&#039;
while (@x &#060;= &#039;04-30-2018&#039;) 
begin
	select @x=dateadd(day,1,@x)
		if datepart(dw,@x)=2 
		begin
		select @x
		end
end]]></description>
			<content:encoded><![CDATA[<p>declare @x date = &#8217;04-01-2018&#8242;<br />
while (@x &lt;= &#039;04-30-2018&#039;)<br />
begin<br />
	select @x=dateadd(day,1,@x)<br />
		if datepart(dw,@x)=2<br />
		begin<br />
		select @x<br />
		end<br />
end</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
