Lets say I have one table with two columns firstname and lastname with String datatype. Normally I write my hql query like
firstname
lastname
\"selec
You may create a calculated column in your entity:
@Formula(value = " concat(first_name, ' ', last_name) ") private String fullName;
And in your HQL you just refer to this field as you would do to any other.
In your case, you can do:
"select fullName from Contact"