That's the best way of doing it.

You have to traverse your object model :)

Mark

On Thu, Aug 12, 2010 at 6:40 PM, Rawlins <rob...@supporttime.com> wrote:

> Hello Chaps,
>
> I've got a few instances in an application where I have a relationship
> in which an entity can have many of another through a 3rd entity. For
> example let me show you my XML configuration.
>
> http://pastebin.com/RuF9USfU
>
> Notice that I have an order object, each order has multiple items in
> it, and each item has a courier assigned to it. Therefor the Order has
> many couriers through an item.
>
> In the application I need to get a list of all couriers assigned to a
> specific order. At the moment I achieve this by adding a
> 'getCouriers()' method to the order decorator which loops over the
> items, creating a struct of the couriers, like so.
>
> http://pastebin.com/nCqZG4GP
>
> However, this just doesn't seem all that efficient to me, is there a
> better way of doing this?
>
> Thanks guys,
>
> Robert
>
> --
> Before posting questions to the group please read:
>
> http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer
>
> Try out the new Transfer ORM Custom Google Search:
> http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8
>
> You received this message because you are subscribed to the Google Groups
> "transfer-dev" group.
> To post to this group, send email to transfer-dev@googlegroups.com
> To unsubscribe from this group, send email to
> transfer-dev+unsubscr...@googlegroups.com<transfer-dev%2bunsubscr...@googlegroups.com>
> For more options, visit this group at
> http://groups.google.com/group/transfer-dev?hl=en
>



-- 
E: mark.man...@gmail.com
T: http://www.twitter.com/neurotic
W: www.compoundtheory.com

cf.Objective(ANZ) - Nov 18, 19 - Melbourne Australia
http://www.cfobjective.com.au

Hands-on ColdFusion ORM Training
www.ColdFusionOrmTraining.com

-- 
Before posting questions to the group please read:
http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer

Try out the new Transfer ORM Custom Google Search:
http://www.google.com/cse/home?cx=002375903941309441958:2s7wbd5ocb8

You received this message because you are subscribed to the Google Groups 
"transfer-dev" group.
To post to this group, send email to transfer-dev@googlegroups.com
To unsubscribe from this group, send email to 
transfer-dev+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/transfer-dev?hl=en

Reply via email to