Wednesday, March 30, 2011

Re: saveAll and validate=>only

thx for the clarification!
makes sense

but since i cannot use transactions (mysql, isam), atomic is set to
false (wouldnt make sense),
therefore the individual results

I now do it this way:
if (CommonComponent::logicalAnd($this->BoardTopic->saveAll($this-
>data['BoardTopic'], array('validate'=>'only')))) {...}


On 29 Mrz., 20:43, 0x20h <k...@informatik.uni-marburg.de> wrote:
> Am 29.03.2011 19:07, schrieb euromark:> i would expect saveAll to return either true or false
> > but instead it returns an array with the individual results
>
> The return value depends on the 'atomic' option. You should get a
> boolean return value when
> 'atomic' is set to true (which is the default) and an array with the
> individual results when set to false.
>
> hth
> Jan

--
Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions.


To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate