开发者

How to get ResultSetMetaData from Entity Manager?

开发者 https://www.devze.com 2023-02-14 18:52 出处:网络
Is there a way to get the MetaData of the result returned by executing a nativeQuery on an Entity Manager in 开发者_StackOverflowJPA?AFAIK there is no way of getting the result set metadata since ther

Is there a way to get the MetaData of the result returned by executing a nativeQuery on an Entity Manager in 开发者_StackOverflowJPA?


AFAIK there is no way of getting the result set metadata since there is no way really, of getting the result set. But, turn it around: what do you want the meta data for? Most of the information from the result set metadata you already have to have to be able to annotate your entity classes. The result set from conventional SQL/JDBC and the List you get from the EntityManager differs conceptually even if they can express the same semantics.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号