Hi All,
For some reason I'm not able to make the @OrderColumn annotation work. The test case is attached to the thread.
Kind regards
Hi All,
For some reason I'm not able to make the @OrderColumn annotation work. The test case is attached to the thread.
Kind regards
As stated on this documentation page, this ORM/SQL annotation is silently ignored by ObjectDB. This is because ObjectDB does not map entity objects to underlying tables and therefore does not handle columns.
However, you can use use the OrderBy annotation, and if you are using an embedded collection (i.e. a collection which is not mapped by) order is preserved by ObjectDB automatically with no need for an order field.
I'm sorry for the inconvenience and thank you for the tips. I'm going to give a try to the embedded collection.