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
  • 962
  • 5
  • 21
  • 49

1 Answers1

0

Did you try

order by a.bookNbr desc, coalesce(b.auth_name, b.last_name + " " + b.first_name))
prayagupa
  • 28,818
  • 13
  • 146
  • 190