[Dbix-class] Recursive update_or_create - RFC

Zbigniew Lukasiak zzbbyy at gmail.com
Sat Feb 7 10:36:40 GMT 2009


> Right, so by specifying pk => undef you're basically saying "don't
> bother with the find, just do the create". I think probably we could need a
> more elegant way to specify this.
>
> Other than that I think this could be useful.
>

I have got rid of that - now it expects an additional array ref with
all the pk columns that are fixed in the resultset.  So for the common
case - when the resultset is not restricted by a pk - you supply the
update hashref and this works as expected, but still it can be made to
work in the less usual case.  Does that meet your expectations?

You might check the new version the repository:
http://dev.catalyst.perl.org/repos/bast/DBIx-Class-ResultSet-RecursiveUpdate/1.000/trunk

-- 
Zbigniew Lukasiak
http://brudnopis.blogspot.com/
http://perlalchemy.blogspot.com/



More information about the DBIx-Class mailing list