<?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: Why should I use an ORM?</title>
	<atom:link href="http://blog.afoolishmanifesto.com/archives/1031/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.afoolishmanifesto.com/archives/1031</link>
	<description>fREWdiculous!</description>
	<lastBuildDate>Mon, 16 Jan 2012 12:16:26 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Chris Prather</title>
		<link>http://blog.afoolishmanifesto.com/archives/1031/comment-page-1#comment-570</link>
		<dc:creator>Chris Prather</dc:creator>
		<pubDate>Thu, 27 Aug 2009 15:12:09 +0000</pubDate>
		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1031#comment-570</guid>
		<description>&quot;ORM’s let you forget SQL&quot;

I&#039;m gonna take exception to this too. Except in very rare cases the *best* ORMs are the ones that don&#039;t let you forget SQL but that instead normalize SQL so you can forget the crappy implementation your RDBMS vendor provides. This is certainly true of Fey and DBIx::Class. Talking with Matt Trout at one point I pointed he suggested that until you saw the SQL through the DBIC you didn&#039;t really get it, and once I started looking at it that way my DBIC usage became *much* more powerful.

I agree with Stevan that if you really want an OO Paradigm that lets you totally forget SQL a graph store like KiokuDB is the way to go. If you have highly related aggregate data then SQL is the right answer and DBIx::Class is my favorite Perl ORM.</description>
		<content:encoded><![CDATA[<p>&#8220;ORM’s let you forget SQL&#8221;</p>
<p>I&#8217;m gonna take exception to this too. Except in very rare cases the *best* ORMs are the ones that don&#8217;t let you forget SQL but that instead normalize SQL so you can forget the crappy implementation your RDBMS vendor provides. This is certainly true of Fey and DBIx::Class. Talking with Matt Trout at one point I pointed he suggested that until you saw the SQL through the DBIC you didn&#8217;t really get it, and once I started looking at it that way my DBIC usage became *much* more powerful.</p>
<p>I agree with Stevan that if you really want an OO Paradigm that lets you totally forget SQL a graph store like KiokuDB is the way to go. If you have highly related aggregate data then SQL is the right answer and DBIx::Class is my favorite Perl ORM.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: fREW Schmidt</title>
		<link>http://blog.afoolishmanifesto.com/archives/1031/comment-page-1#comment-568</link>
		<dc:creator>fREW Schmidt</dc:creator>
		<pubDate>Thu, 27 Aug 2009 13:58:03 +0000</pubDate>
		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1031#comment-568</guid>
		<description>@Stevan, you&#039;re right.  I stand corrected.  I changed the post a little to reflect that.</description>
		<content:encoded><![CDATA[<p>@Stevan, you&#8217;re right.  I stand corrected.  I changed the post a little to reflect that.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Stevan Little</title>
		<link>http://blog.afoolishmanifesto.com/archives/1031/comment-page-1#comment-566</link>
		<dc:creator>Stevan Little</dc:creator>
		<pubDate>Thu, 27 Aug 2009 13:20:11 +0000</pubDate>
		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1031#comment-566</guid>
		<description>Saying that an ORM gives you &quot;all&quot; the features of OOP is actually wrong. In fact the three main features of OOP are either broken or stilted in ORMS. 

First you can&#039;t easily do inheritance, yes there are patterns you can follow to fake inheritance, but they all end in compromise and tears. 

Second, there is no real polymorphism available. You cannot treat a Employee the same as a Person because the Employee.id will not be in the Person table. Again, you can fake some of this, but thats not real polymorphism then.

Lastly, because your object data is stored in tuples in a RDB you have no real encapsulation. Sure the objects created by your ORM might be encapsulated but a simple errant SQL statement could bring your whole house of cards crashing down.

In the end a RDB is just a tuple store with implied relationships and Objects are a graph with explicit relationships, they are simply not compatible. 

Personally I try to use object graph engines like KiokuDB for my objects and $RDBMS for my tabular data as often as possible.</description>
		<content:encoded><![CDATA[<p>Saying that an ORM gives you &#8220;all&#8221; the features of OOP is actually wrong. In fact the three main features of OOP are either broken or stilted in ORMS. </p>
<p>First you can&#8217;t easily do inheritance, yes there are patterns you can follow to fake inheritance, but they all end in compromise and tears. </p>
<p>Second, there is no real polymorphism available. You cannot treat a Employee the same as a Person because the Employee.id will not be in the Person table. Again, you can fake some of this, but thats not real polymorphism then.</p>
<p>Lastly, because your object data is stored in tuples in a RDB you have no real encapsulation. Sure the objects created by your ORM might be encapsulated but a simple errant SQL statement could bring your whole house of cards crashing down.</p>
<p>In the end a RDB is just a tuple store with implied relationships and Objects are a graph with explicit relationships, they are simply not compatible. </p>
<p>Personally I try to use object graph engines like KiokuDB for my objects and $RDBMS for my tabular data as often as possible.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Adam Kennedy</title>
		<link>http://blog.afoolishmanifesto.com/archives/1031/comment-page-1#comment-564</link>
		<dc:creator>Adam Kennedy</dc:creator>
		<pubDate>Thu, 27 Aug 2009 08:30:45 +0000</pubDate>
		<guid isPermaLink="false">http://blog.afoolishmanifesto.com/?p=1031#comment-564</guid>
		<description>In the case of my ORM ORLite, it&#039;s that I can have a whole class tree of useful code with literally one line declaration :)</description>
		<content:encoded><![CDATA[<p>In the case of my ORM ORLite, it&#8217;s that I can have a whole class tree of useful code with literally one line declaration <img src='http://blog.afoolishmanifesto.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
</channel>
</rss>

