I'm trying to execute a the following query, but it doesn't work.
select i.name|| ' - ' || i.name from Item i
I'm getting this excpetion:
org.hibernate.QueryException: , expected in SELECT [select i.name || ' - ' || i.name from com.(...).Item i]
I could resolve it using the concat(...) function. I found another issue. This query works properly:
select concat(i.name, concat(' - ', i.name)) from Item i
but this doesn't:
select concat(concat(i.name, ' - '), i.name) from Item i
I'm tried this with the last version of hibernate and oracle as db.
Any idea?
|