Hi Diego,

Please see my blogs about this subject:

http://future500.nl/doctrine-2-how-to-handle-join-tables-with-extra-columns/
http://future500.nl/more-on-one-to-manymany-to-one-associations-in-doctrine-2/

-- 
Jasper N. Brouwer
(@jaspernbrouwer)


On 18 Dec 2013, at 16:10, Diego Perlman <[email protected]> wrote:

> I have a MANY-TO-MANY relationship.
> 
> It works fine, but now I have to include a FIELD to keep an order.
> 
> I have this:
> 
> <many-to-many field="purchaseorders" target-entity="PurchaseOrder"
> inversed-by="commercialinvoices">
> 
>            <join-table name="commercialinvoicepurchaseorder">
> 
>                <join-columns>
> 
>                <join-column name="commercialinvoice_id"
> referenced-column-name="id"></join-column>
> 
>                </join-columns>
> 
>                <inverse-join-columns>
> 
>                <join-column name="purchaseorder_id"
> referenced-column-name="id"></join-column>
> 
>                </inverse-join-columns>
> 
>            </join-table>
> 
>        </many-to-many>
> 
> I want to ORDER the INSERT, If I insert 99,213,98 I want to keep this
> order but in MYSQL it stores like 98,99,213 so that's why I need
> another FIELD in the relationship to control de ORDER.
> 
> Someone can help me with this?
> 
> Regards
> Diego

-- 
You received this message because you are subscribed to the Google Groups 
"doctrine-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/doctrine-user.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to