I want to use SYS_CONNECT_BY_PATH function to map hierarchy query in Hibernate, but hibernate keeps throwing “Missing right parenthesis” error. This is the query I have:
<property name="refValCatHierarchy" formula="(select SYS_CONNECT_BY_PATH(cat.cat_name, ' > ') from T_CFG_REFERENCE_VALUE_CATEGORY where cat.rv_cat_id = id connect by prior cat.rv_cat_id = cat.prnt_id start with cat.rv_cat_id != 0)"/>
The table structure is this: Primary Key: cat_id Parent ID: prnt_id
This query works fine when I run it in Oracle
Any help will be appreciated.
|