I am a bit surprised by the way JBoss orders the columns in relationship tables which seems reverse to me.

 

Say I have two EJBs called A and B and a relation ship between them, then, if I map this relationship as shown below, the database table created seems reversed having the column order TheKeyOfB, TheKeyOfA rather than TheKeyOfA, TheKeyOfB. This seems odd to me – is it intentional, and can it be prevented?

 

 

Randahl

 

                                    <ejb-relationship-role>

                                                <ejb-relationship-role-name>A-has-B</ejb-relationship-role-name>

                                                <key-fields>

                                                            <key-field>

                                                                        <field-name>primaryKey</field-name>

                                                                        <column-name>TheKeyOfA</column-name>

                                                            </key-field>

                                                </key-fields>

                                    </ejb-relationship-role>

                                    <ejb-relationship-role>

                                                <ejb-relationship-role-name>A-belongsTo-B</ejb-relationship-role-name>

                                                <key-fields>

                                                            <key-field>

                                                                        <field-name>primaryKey</field-name>

                                                                        <column-name>TheKeyOfB</column-name>

                                                            </key-field>

                                                </key-fields>

                                    </ejb-relationship-role>

 

Reply via email to