Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] Indexing the FK of a table generated for an element collection ?

Hi all,

I have a quick question regarding DDL generation of indexes for element collections.

I have a class in which exists a property which is a list of strings, and is annotated with element collection.  The declaration is simply as follows:

@ElementCollection
@OrderColumn
private List<String> details;

When the DDL is generated, a details table is created with a FK pointing back to the table corresponding to the class containing the list property.  There's not a separate class for the elements of the embedded collection for me to annotate with @Indexes/@Index annotation... since the type is String.  Is there a way to annotate something else to have DDL generation create the index on the FK of the embedded collection table or will I have to do this manually?

Thanks!
- Phillip

Back to the top