Michael Higgins wrote:
Right. I want to update the record as defined by that primary key.

I guess I found the answer:
->update_or_create({

Seems to do the trick, checking for unique and updating with other values
posted. Too easy, as usual.  ;-)

Cheers,

Ignore my response as well then... ;)

(Though it might be useful for others, I see people trying to do this *way* too often even though you weren't)

Yep, the update_or_create method is extremely useful and pretty slick. I usually have to write a stored procedure to make sure this gets done correctly, but once again DBIC does it the right way out of the box!

Danny


_______________________________________________
List: Catalyst@lists.rawmode.org
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
Dev site: http://dev.catalyst.perl.org/

Reply via email to