|
|
Re: Mapping entity property to stored functioncall - possible? [message #513761 is a reply to message #513036] |
Thu, 11 February 2010 02:57  |
Eclipse User |
|
|
|
Am 08.02.2010 17:02, schrieb James:
> There is no easy way to do this, so please log an enhancement request.
Done.
>
> Some options include,
> - Use an EclipseLink Converter to perform the same conversion in Java as
> the database function would.
> - Define a database view that applies the function, and map to the view
> instead of the table.
> - Use custom SQL to map to the object, using a DescriptorCustomizer you
> can override the readObject and readAll queries to use your own custom SQL.
> - Use the function name inside the @Column name, this will work for
> simple one table SQL, but will fail for joins when aliases are used.
> - Subclass DatabaseField to handle printing functions and set it into
> your mapping.
>
|
|
|
Powered by
FUDForum. Page generated in 0.09388 seconds