On Tue, Jun 26, 2007 at 04:30:26PM -0700, Marc Mims wrote:
> * Steve Francia <[EMAIL PROTECTED]> [070626 16:00]:
> > Sadly, that is the way we had it, we decided to switch to using the 
> > owner flag to try to eliminate duplication of data in the database.
> 
> At least in the problem you presented, I don't see the data duplication
> problem with a foreign key to the user table in the picture table.  The
> key itself would exist in both the picture table and the user_picture
> table, but I think that is a natural consequence of the relationships.

Actually, I'd probably have the owner_id be part of a compound FK to
user_picture rather than user - enforces that that link exists ...

-- 
      Matt S Trout       Need help with your Catalyst or DBIx::Class project?
   Technical Director    Want a managed development or deployment platform?
 Shadowcat Systems Ltd.  Contact mst (at) shadowcatsystems.co.uk for a quote
http://chainsawblues.vox.com/             http://www.shadowcatsystems.co.uk/ 

_______________________________________________
List: http://lists.rawmode.org/cgi-bin/mailman/listinfo/dbix-class
Wiki: http://dbix-class.shadowcatsystems.co.uk/
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/trunk/DBIx-Class/
Searchable Archive: http://www.mail-archive.com/[email protected]/

Reply via email to