Hi,

On Wed, Jan 19, 2011 at 9:46 PM, kdubya <[email protected]> wrote:

> So, to summarize, I can either use saveAll() to
>
> 1) save a single record of the main model (in this case Item) WITH
> it's related models (see note below)
>
> - OR -
>
> 2) save multiple instances of the main model (Item) WITHOUT it's
> related models (see note below)
>
> - BUT -
>
> Not both. Is this correct?
>

- Yes, you are absolutely right.


>
> Note:
> In the CakePHP book (Cake 1.2 collection) in the section on saving
> data  (http://book.cakephp.org/view/75/Saving-Your-Data) it talks in
> the saveAll() portion about saving hasOne and belongsTo relation and
> shows how to save multiple records. It also show below that saving a
> SINGLE record of a model with hasMany relations where the hasMAny
> model has multiple records.
>
> I guess my mistake was to assume you could extend that to saving
> multiple records of a model with sub-model data as well.
>
> --
> 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
> [email protected]<cake-php%[email protected]>For
>  more options, visit this group at
> http://groups.google.com/group/cake-php
>


Amit Badkas

PHP Applications for E-Biz: http://www.sanisoft.com

-- 
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
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php

Reply via email to