<?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: Beating a dead horse: Stored Procedures</title>
	<atom:link href="http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/feed/" rel="self" type="application/rss+xml" />
	<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/</link>
	<description>thoughts.each { &#38;:propagandise }</description>
	<lastBuildDate>Sun, 14 Mar 2010 17:21:13 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Business Logic in Stored Procedures is bad! &#171; Rounded Corners</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-582</link>
		<dc:creator>Business Logic in Stored Procedures is bad! &#171; Rounded Corners</dc:creator>
		<pubDate>Tue, 30 Jun 2009 04:21:49 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-582</guid>
		<description>&lt;p&gt;[...] Beating a dead horse: Stored Procedures Mind your PQs Stored procedures are bad, m&#8217;kay? Good and Evil in the Garden of Stored Procedures Why I do not use Stored Procedures [...]&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>[...] Beating a dead horse: Stored Procedures Mind your PQs Stored procedures are bad, m&#8217;kay? Good and Evil in the Garden of Stored Procedures Why I do not use Stored Procedures [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: shane</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-410</link>
		<dc:creator>shane</dc:creator>
		<pubDate>Tue, 28 Oct 2008 03:13:37 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-410</guid>
		<description>I would say your argument is 100% correct if all you were talking about is CRUD operations - but there is often more to it than that.
There are many times i have had to massage or pivot data requested by an application, and the best way to do that is with a stored proc. There have also been times when business logic needed to be included in the database, this requires a trigger or a stored proc. There are also times when multiple applications need the same data, the best way to effect this is with stored procs.
You have to remember that Linq2Sql is still relatively new, and possibly misunderstood. And not everybody has it (unless the whole world uses .Net exclusively), or has the ability to move to it immediately. I&#039;m sure Linq2Sql would cover maybe 70 or 80% of development needs, but there will always be that 20%  that it doesn&#039;t.
I think what you are most pissed at is that people religiously promote the use of stored procs and refuse to consider or comprehend other technologies that could be as good or better - you will never change those people :)</description>
		<content:encoded><![CDATA[<p>I would say your argument is 100% correct if all you were talking about is CRUD operations &#8211; but there is often more to it than that.<br />
There are many times i have had to massage or pivot data requested by an application, and the best way to do that is with a stored proc. There have also been times when business logic needed to be included in the database, this requires a trigger or a stored proc. There are also times when multiple applications need the same data, the best way to effect this is with stored procs.<br />
You have to remember that Linq2Sql is still relatively new, and possibly misunderstood. And not everybody has it (unless the whole world uses .Net exclusively), or has the ability to move to it immediately. I&#8217;m sure Linq2Sql would cover maybe 70 or 80% of development needs, but there will always be that 20%  that it doesn&#8217;t.<br />
I think what you are most pissed at is that people religiously promote the use of stored procs and refuse to consider or comprehend other technologies that could be as good or better &#8211; you will never change those people <img src='http://flanders.co.nz/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: 2008 October 24 - Links for today &#171; My (almost) Daily Links</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-409</link>
		<dc:creator>2008 October 24 - Links for today &#171; My (almost) Daily Links</dc:creator>
		<pubDate>Mon, 27 Oct 2008 07:09:30 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-409</guid>
		<description>[...] Ivan Porto Carrero is trying to stop Beating a dead horse: Stored Procedures [...]</description>
		<content:encoded><![CDATA[<p>[...] Ivan Porto Carrero is trying to stop Beating a dead horse: Stored Procedures [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Abhishek</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-408</link>
		<dc:creator>Abhishek</dc:creator>
		<pubDate>Mon, 27 Oct 2008 03:42:11 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-408</guid>
		<description>I remember one of my previous projects heavily relying on Stored Procedures. The prime reason was the kind of database interaction required. Our app server and DB server were in different locations. We required to perform a very data intensive operation based on multiple parameters from client systems. The best approach was to use Stored Procs and it indeed scaled very well. Most of our data oriented logic which required data aggregation from several tables and return back to the app server in specific format was all written in stored procs. Also, another module which required some intelligent snapshot generation of certain part of the table required data to be processed in a complex manner and do segmentation of individual snapshots and store it in staging tables which was to be distributed to the clients based on business logics. I think in this scenario it was a wise decision to go with Stored Procs. So, IMO we can&#039;t conclude that SPs are completely avoidable. We can agree on the fact it should be used in certain situations and shouldn&#039;t be used as one stop solution for each DB interaction.</description>
		<content:encoded><![CDATA[<p>I remember one of my previous projects heavily relying on Stored Procedures. The prime reason was the kind of database interaction required. Our app server and DB server were in different locations. We required to perform a very data intensive operation based on multiple parameters from client systems. The best approach was to use Stored Procs and it indeed scaled very well. Most of our data oriented logic which required data aggregation from several tables and return back to the app server in specific format was all written in stored procs. Also, another module which required some intelligent snapshot generation of certain part of the table required data to be processed in a complex manner and do segmentation of individual snapshots and store it in staging tables which was to be distributed to the clients based on business logics. I think in this scenario it was a wise decision to go with Stored Procs. So, IMO we can&#8217;t conclude that SPs are completely avoidable. We can agree on the fact it should be used in certain situations and shouldn&#8217;t be used as one stop solution for each DB interaction.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Thomas Hansen</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-407</link>
		<dc:creator>Thomas Hansen</dc:creator>
		<pubDate>Sun, 26 Oct 2008 14:40:01 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-407</guid>
		<description>Great writeup, though I didn&#039;t even consider this to be a serious debate any longer myself in fact. I thought this was at the level of &quot;OO is great&quot; and &quot;black box helps maintenance&quot; and such...
Are anybody out there *seriously* using SPs...?
(Except VB6 maintenance guys that is...)
Btw, John Rusk&#039;s comment about MSFT using SPs to &quot;lock people in&quot; I think is a brilliant observation which I didn&#039;t really think was that mainstream (outside of my head that is)
When History is about to be written MSFT has a *lot* to answer for in fact in regards to misinformation like SPs and such...!</description>
		<content:encoded><![CDATA[<p>Great writeup, though I didn&#8217;t even consider this to be a serious debate any longer myself in fact. I thought this was at the level of &#8220;OO is great&#8221; and &#8220;black box helps maintenance&#8221; and such&#8230;<br />
Are anybody out there *seriously* using SPs&#8230;?<br />
(Except VB6 maintenance guys that is&#8230;)<br />
Btw, John Rusk&#8217;s comment about MSFT using SPs to &#8220;lock people in&#8221; I think is a brilliant observation which I didn&#8217;t really think was that mainstream (outside of my head that is)<br />
When History is about to be written MSFT has a *lot* to answer for in fact in regards to misinformation like SPs and such&#8230;!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Clay Lenhart</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-406</link>
		<dc:creator>Clay Lenhart</dc:creator>
		<pubDate>Sun, 26 Oct 2008 10:18:02 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-406</guid>
		<description>The Stored Procedure debate is a good one.  You may have missed one aspect of security in the debate.  If sql server logins can only execute stored procedures, then the actions are limited to the code in those stored procedures.  If there are no DELETE statements in the stored procedures, then a malicous user cannot delete anything (or even DROP).  I posted exact how to go about this type of security, and in fact, it is very easy to &quot;get right&quot; -- ie, you&#039;ll never get a mismatch of code and security constraints (where the code tries to do something that the security constraints do not allow).
http://clay.lenharts.net/blog/2008/01/24/sql-server-security-with-execute-as-owner/</description>
		<content:encoded><![CDATA[<p>The Stored Procedure debate is a good one.  You may have missed one aspect of security in the debate.  If sql server logins can only execute stored procedures, then the actions are limited to the code in those stored procedures.  If there are no DELETE statements in the stored procedures, then a malicous user cannot delete anything (or even DROP).  I posted exact how to go about this type of security, and in fact, it is very easy to &#8220;get right&#8221; &#8212; ie, you&#8217;ll never get a mismatch of code and security constraints (where the code tries to do something that the security constraints do not allow).<br />
<a href="http://clay.lenharts.net/blog/2008/01/24/sql-server-security-with-execute-as-owner/" rel="nofollow">http://clay.lenharts.net/blog/2008/01/24/sql-server-security-with-execute-as-owner/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dew Drop - October 24, 2008 &#124; Alvin Ashcraft's Morning Dew</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-403</link>
		<dc:creator>Dew Drop - October 24, 2008 &#124; Alvin Ashcraft's Morning Dew</dc:creator>
		<pubDate>Fri, 24 Oct 2008 13:19:25 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-403</guid>
		<description>[...] Beating a Dead Horse: Stored Procedures (Ivan Porto Carrero) [...]</description>
		<content:encoded><![CDATA[<p>[...] Beating a Dead Horse: Stored Procedures (Ivan Porto Carrero) [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Rusk</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-401</link>
		<dc:creator>John Rusk</dc:creator>
		<pubDate>Fri, 24 Oct 2008 08:27:11 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-401</guid>
		<description>PS: Some limitations of LINQ to SQL, when working with stored procs, are noted here: http://oakleafblog.blogspot.com/2007/09/problems-using-stored-procedures-for_08.html Apparently using stored procs adversly affects LINQ to SQL&#039;s change tracking and lazy loading.</description>
		<content:encoded><![CDATA[<p>PS: Some limitations of LINQ to SQL, when working with stored procs, are noted here: <a href="http://oakleafblog.blogspot.com/2007/09/problems-using-stored-procedures-for_08.html" rel="nofollow">http://oakleafblog.blogspot.com/2007/09/problems-using-stored-procedures-for_08.html</a> Apparently using stored procs adversly affects LINQ to SQL&#8217;s change tracking and lazy loading.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Rusk</title>
		<link>http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/comment-page-1/#comment-400</link>
		<dc:creator>John Rusk</dc:creator>
		<pubDate>Fri, 24 Oct 2008 08:19:28 +0000</pubDate>
		<guid isPermaLink="false">http://flanders.co.nz/2008/10/23/beating-a-dead-horse-stored-procedures/#comment-400</guid>
		<description>Hi Ivan,

I agree with you.

By the way, I think this comment from Frans is arguably even better than the article you link to above: http://www.theserverside.net/news/thread.tss?thread_id=31953#158113  He begins by describing two different kinds of stored procedures, and explaining that one is OK and the other is not.  I think he describes it very well.

To me, a key to any real progress on this debate is some correct and meaningful guidance on it from Microsoft.  They&#039;ll need to make it clear to the community that they are putting aside any self-interest they may have in locking developers into the SQL Server plaform (as is the result when using T-SQL) and instead give comprehensive and accurate advice.  For instance, there is no use in making outright incorrect statements in widely-read guidance (see http://dotnet.agilekiwi.com/blog/2008/08/practical-step-in-stored-proc-debate.html )  

By the way, I raise the point about the need to explictly put aside self interest because I&#039;ve heard, more than once, that Microsoft give biased advice on this topic to promote lock-in to SQL Server. If that&#039;s true, it needs to change.  It is inconsistent with Microsoft&#039;s increasingly open approach in recent years. If its false, then MS should demonstrate that it&#039;s false.

The good news is that Microsoft are currently writing a new draft of their guidance, and it is fully open for community feedback on CodePlex.  What we need is for everyone who&#039;s concerned about this issue (and other aspects of .NET arhitecture) to get over there and leave comments and/or add items to the &quot;Discussion&quot; tab.

Here&#039;s an intro to MS&#039;s new guidance, from an ALT.NET perspective: http://codebetter.com/blogs/jeremy.miller/archive/2008/09/11/p-amp-p-architectural-guidance-version-2.aspx</description>
		<content:encoded><![CDATA[<p>Hi Ivan,</p>
<p>I agree with you.</p>
<p>By the way, I think this comment from Frans is arguably even better than the article you link to above: <a href="http://www.theserverside.net/news/thread.tss?thread_id=31953#158113" rel="nofollow">http://www.theserverside.net/news/thread.tss?thread_id=31953#158113</a>  He begins by describing two different kinds of stored procedures, and explaining that one is OK and the other is not.  I think he describes it very well.</p>
<p>To me, a key to any real progress on this debate is some correct and meaningful guidance on it from Microsoft.  They&#8217;ll need to make it clear to the community that they are putting aside any self-interest they may have in locking developers into the SQL Server plaform (as is the result when using T-SQL) and instead give comprehensive and accurate advice.  For instance, there is no use in making outright incorrect statements in widely-read guidance (see <a href="http://dotnet.agilekiwi.com/blog/2008/08/practical-step-in-stored-proc-debate.html" rel="nofollow">http://dotnet.agilekiwi.com/blog/2008/08/practical-step-in-stored-proc-debate.html</a> )  </p>
<p>By the way, I raise the point about the need to explictly put aside self interest because I&#8217;ve heard, more than once, that Microsoft give biased advice on this topic to promote lock-in to SQL Server. If that&#8217;s true, it needs to change.  It is inconsistent with Microsoft&#8217;s increasingly open approach in recent years. If its false, then MS should demonstrate that it&#8217;s false.</p>
<p>The good news is that Microsoft are currently writing a new draft of their guidance, and it is fully open for community feedback on CodePlex.  What we need is for everyone who&#8217;s concerned about this issue (and other aspects of .NET arhitecture) to get over there and leave comments and/or add items to the &#8220;Discussion&#8221; tab.</p>
<p>Here&#8217;s an intro to MS&#8217;s new guidance, from an ALT.NET perspective: <a href="http://codebetter.com/blogs/jeremy.miller/archive/2008/09/11/p-amp-p-architectural-guidance-version-2.aspx" rel="nofollow">http://codebetter.com/blogs/jeremy.miller/archive/2008/09/11/p-amp-p-architectural-guidance-version-2.aspx</a></p>
]]></content:encoded>
	</item>
</channel>
</rss>
