Hello Hibernate guru's,
I have a set of view in DB as data source. I define some composite id's for these views in corresponding hibernate mappings.
The data quality is poor so there exist rows in views which have null values in composite id member fields. But nevertheless such rows have to be processed.
Basically I would like hibernate to simply convert JDBC result sets directly to detached object lists without any persistance stuff.
Is this
persiter option the thing I need?
And how should I define ClassPersister if yes?
I've found a workaround with HQL using following construct:
Code:
select new MyDomainObject(field1, field2) from MyDomainObject mdo where mdo.field1=value1
But I really love (and basically use) hibernate for it's criteria queries.
So I've found out that there is
persiter option in mapping and I could define a custom ClassPersister. But unfortunately I've failed to understand code and documentation :)