My setup

Blogs
- hasMany Posts
- hasAndBelongsToMany Accounts

Post
- belongsTo Blog
- belongsTo Account
-hasMany Note

Note
- belongsTo Post
- belongsTo Account

Account
- hasMany Post
- hasMany Note
- hasAndBelongsToMany Blog

The issue comes when I am in Posts and I do a recursive = 2, which I
think should pull the post information, the note information and the
account information associated with the note.

However, gets the list of note_id's and queries the post tables for
the note_id's.  This example has 4 notes
SELECT Post.id, Post.title, Post.text, Post.created, Post.modified,
Post.blog_id, Post.account_id, Post.ip FROM cake_posts Post WHERE
Post.id = 10
SELECT Post.id, Post.title, Post.text, Post.created, Post.modified,
Post.blog_id, Post.account_id, Post.ip FROM cake_posts Post WHERE
Post.id = 11
SELECT Post.id, Post.title, Post.text, Post.created, Post.modified,
Post.blog_id, Post.account_id, Post.ip FROM cake_posts Post WHERE
Post.id = 12
SELECT Post.id, Post.title, Post.text, Post.created, Post.modified,
Post.blog_id, Post.account_id, Post.ip FROM cake_posts Post WHERE
Post.id = 13

Then it does the same to the accounts
SELECT Account.id, Account.username, Account.first_name,
Account.last_name, Account.email, Account.profile_pic FROM
cake_accounts Account WHERE Account.id = 10
SELECT Account.id, Account.username, Account.first_name,
Account.last_name, Account.email, Account.profile_pic FROM
cake_accounts Account WHERE Account.id = 11
SELECT Account.id, Account.username, Account.first_name,
Account.last_name, Account.email, Account.profile_pic FROM
cake_accounts Account WHERE Account.id = 12
SELECT Account.id, Account.username, Account.first_name,
Account.last_name, Account.email, Account.profile_pic FROM
cake_accounts Account WHERE Account.id = 13

What am I doing wrong?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to