<?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: How do your DBIC result base classes look like?</title>
	<atom:link href="http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/</link>
	<description>Just another web developer's weblog</description>
	<lastBuildDate>Mon, 29 Jun 2009 22:55:48 +0200</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Moritz Onken</title>
		<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/comment-page-1/#comment-19</link>
		<dc:creator>Moritz Onken</dc:creator>
		<pubDate>Fri, 22 May 2009 17:42:18 +0000</pubDate>
		<guid isPermaLink="false">http://blog.netcubed.de/?p=56#comment-19</guid>
		<description>Thanks for your thoughts on this.

The reason why I drop those constraints is that I had some problems when I tried to populate my database (e.g. with a dump). PostgreSQL complained on a regular basis that some foreign key constraints are violated. So I thought dropping them altogether would save me from that problem. 

Anyway, I think it wasn&#039;t the best idea and there is probably a different way to work around this.</description>
		<content:encoded><![CDATA[<p>Thanks for your thoughts on this.</p>
<p>The reason why I drop those constraints is that I had some problems when I tried to populate my database (e.g. with a dump). PostgreSQL complained on a regular basis that some foreign key constraints are violated. So I thought dropping them altogether would save me from that problem. </p>
<p>Anyway, I think it wasn&#8217;t the best idea and there is probably a different way to work around this.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Moritz Onken</title>
		<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/comment-page-1/#comment-18</link>
		<dc:creator>Moritz Onken</dc:creator>
		<pubDate>Fri, 22 May 2009 17:35:31 +0000</pubDate>
		<guid isPermaLink="false">http://blog.netcubed.de/?p=56#comment-18</guid>
		<description>I thought DBIC would try to load that class. Did not try it yet :-)</description>
		<content:encoded><![CDATA[<p>I thought DBIC would try to load that class. Did not try it yet :-)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: fREW Schmidt</title>
		<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/comment-page-1/#comment-17</link>
		<dc:creator>fREW Schmidt</dc:creator>
		<pubDate>Fri, 22 May 2009 02:01:29 +0000</pubDate>
		<guid isPermaLink="false">http://blog.netcubed.de/?p=56#comment-17</guid>
		<description>Why do you do MySchema::Base::Result instead of just MySchema::Result?</description>
		<content:encoded><![CDATA[<p>Why do you do MySchema::Base::Result instead of just MySchema::Result?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pedro Melo</title>
		<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/comment-page-1/#comment-16</link>
		<dc:creator>Pedro Melo</dc:creator>
		<pubDate>Thu, 21 May 2009 20:08:15 +0000</pubDate>
		<guid isPermaLink="false">http://blog.netcubed.de/?p=56#comment-16</guid>
		<description>Hi,

my base class for Result&#039;s starts simply as

package Base;

use strict;
use warnings;
use base &#039;DBIx::Class&#039;;

__PACKAGE__-&gt;load_components(qw(InflateColumn::DateTime Core));

1;

I don&#039;t know why your DBIC is asking you to declare a table, or even columns, that does not make any sense to me.

I have others, more complex, including one that keeps track of all changes to the table.

Best regards,</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>my base class for Result&#8217;s starts simply as</p>
<p>package Base;</p>
<p>use strict;<br />
use warnings;<br />
use base &#8216;DBIx::Class&#8217;;</p>
<p>__PACKAGE__-&gt;load_components(qw(InflateColumn::DateTime Core));</p>
<p>1;</p>
<p>I don&#8217;t know why your DBIC is asking you to declare a table, or even columns, that does not make any sense to me.</p>
<p>I have others, more complex, including one that keeps track of all changes to the table.</p>
<p>Best regards,</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matt S Trout</title>
		<link>http://blog.netcubed.de/2009/05/how-do-your-dbic-result-base-classes-look-like/comment-page-1/#comment-13</link>
		<dc:creator>Matt S Trout</dc:creator>
		<pubDate>Thu, 21 May 2009 12:10:50 +0000</pubDate>
		<guid isPermaLink="false">http://blog.netcubed.de/?p=56#comment-13</guid>
		<description>You&#039;re insane. DBIx::Class does *not* &quot;handle foreign keys anyway&quot;, it&#039;s designed to do things correctly on an actual database and only incidentally, probably, work on sqlite or MyISAM.

Throwing away your foreign keys like that is intensely scary - it&#039;s like going through every line of perl on your system deleting &#039;use strict&#039; and &#039;use warnings&#039; and at least as dangerous.

And as for &quot;Since I’m a little bit paranoid about collision I set the check parameter so the component checks before inserting a new row if a column with that id is already there&quot; - if you actually care, call -&gt;add_unique_constraint to constrain it on the database side.

Constraints are good. use them.

-- mst</description>
		<content:encoded><![CDATA[<p>You&#8217;re insane. DBIx::Class does *not* &#8220;handle foreign keys anyway&#8221;, it&#8217;s designed to do things correctly on an actual database and only incidentally, probably, work on sqlite or MyISAM.</p>
<p>Throwing away your foreign keys like that is intensely scary &#8211; it&#8217;s like going through every line of perl on your system deleting &#8216;use strict&#8217; and &#8216;use warnings&#8217; and at least as dangerous.</p>
<p>And as for &#8220;Since I’m a little bit paranoid about collision I set the check parameter so the component checks before inserting a new row if a column with that id is already there&#8221; &#8211; if you actually care, call -&gt;add_unique_constraint to constrain it on the database side.</p>
<p>Constraints are good. use them.</p>
<p>&#8211; mst</p>
]]></content:encoded>
	</item>
</channel>
</rss>
