Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "Configuring an Object-Relational Data Type Descriptor (ELUG)"
m |
m (227400) |
||
(One intermediate revision by the same user not shown) | |||
Line 176: | Line 176: | ||
<span id="Example 31-1"></span> | <span id="Example 31-1"></span> | ||
''''' Field Ordering''''' | ''''' Field Ordering''''' | ||
+ | <source lang="java"> | ||
descriptor.addFieldOrdering("ID"); | descriptor.addFieldOrdering("ID"); | ||
descriptor.addFieldOrdering("F_NAME"); | descriptor.addFieldOrdering("F_NAME"); | ||
descriptor.addFieldOrdering("L_NAME"); | descriptor.addFieldOrdering("L_NAME"); | ||
− | + | </source> | |
Line 189: | Line 190: | ||
[[Category: EclipseLink User's Guide]] | [[Category: EclipseLink User's Guide]] | ||
− | [[Category: | + | [[Category: Release 1]] |
[[Category: Task]] | [[Category: Task]] | ||
[[Category: ORM]] | [[Category: ORM]] |
Latest revision as of 09:45, 20 May 2009
For information on how to create object-relational data type descriptors, see Creating an Object-Relational Data Type Descriptor.
This table lists the configurable options for an object-relational data type descriptor.
Option to Configure | EclipseLink Workbench | Java |
---|---|---|
For more information, see Introduction to Relational Descriptors.
Configuring Field Ordering
If your object-relational data type data source driver uses JDBC indexed arrays, you can specify the order in which EclipseLink persists object attributes to define the field index.
How to Configure Field Ordering Using Java
Use ObjectRelationalDescriptor method addFieldOrdering to specify the field ordering. This example shows how to specify the order of the object-relational data type database fields OBJECT_ID, F_NAME, and L_NAME for the Employee descriptor.
Field Ordering
descriptor.addFieldOrdering("ID"); descriptor.addFieldOrdering("F_NAME"); descriptor.addFieldOrdering("L_NAME");