sql « Oracle « JPA Q&A





1. Wrapping SQL doesn't work with Oracle 9    forum.hibernate.org

I have the following query produced by Hibernate: select * from ( select distinct document0_.DOC_RSN as DOC_RSN0_, doctype5_.DOC_TYPE as DOC_TYPE1_, workitem1_.PARCEL_ID as PARCEL_ID2_, workitem1_.NODE_ID as NODE_ID2_, workitem1_.WFL_ID as WFL_ID2_, folder3_.FLD_RSN as FLD_RSN3_, subfolder4_.SUB_FLD_RSN as SUB_FLD_1_4_, details2_.A_DETAIL_RSN as A_DETAIL1_5_, document0_.COMMIT_CONFIG_ID as COMMIT_C2_0_, document0_.COMMIT_DATE as COMMIT_D3_0_, document0_.DOC_SCAN_UID as DOC_SCAN4_0_, document0_.DOC_SCAN_DATE as DOC_SCAN5_0_, document0_.DOC_DESC as DOC_DESC0_, document0_.TASK_PAR_STR as TASK_PAR7_0_, document0_.IMAGE_FILE as IMAGE_FILE0_, document0_.IMAGE_LOCATION as ...

2. ORA-1006 when using custom sql with @SQLUpdate    forum.hibernate.org

Hi, I want to make an update just of a few columns of my table. For this case I took the update clause which was generated by hibernate and reduced it to the fields I need. Then I put the sql in a @SQLUpdate annotation. The sql is used, but it results in a ORA-01006: bind variable does not exist. I ...