0

I've the following sql query which I need to accommodate using HQL.

A is an Author and B is an Book - Author has Many books

SQL:

order by a.bookNbr desc, nvl(b.auth_name, b.last_name || ' ' || b.first_name))

Any help would be appreciated to convert above sql to HQL.

TP_JAVA
  • 1,002
  • 5
  • 23
  • 49

1 Answers1

0

Did you try

order by a.bookNbr desc, coalesce(b.auth_name, b.last_name + " " + b.first_name))
prayagupa
  • 30,204
  • 14
  • 155
  • 192