Hi
Is there any way to transform the database schema in memory before hibernate will do the actual mapping??
I have a table in a legacy db that looks like this:
Code:
BLACK_REQUEST_PARAM
REQ_ID | NAME | INOUT | VALUE
1 | param1 | I | value1
1 | param2 | I | value2
1 | param3 | O | value3
2 | param1 | I | value4
2 | param2 | I | value5
2 | param3 | O | value6
(...)
However, I want it to be mapped into this:
Code:
public class BlackRequestParamIn {
@Id
private Long reqId;
private String param1;
private String param2;
(...) //other parameters
//non-arg constructor
//getters & setters
}
,
and respective class for out parameters -- just as if DDL was totally different
I know that I can "map" hibernate VO's properties into my own class'es properties in DAO but I was wondering if hibernate is capable of doing something similar before the mapping
thx in advance
pete
PS: the database schema cannot be modified :/