When to use HQL and When to use creteria? i) I mean is there any particular condition where I can use only creteria and not HQL or vice versa? ii) In which condition it is better to use creteria or vice versa?
Personal preference is about all there is to differentiate. Criteria have the advantage of not being open to syntax errors, HQL is (to my mind) easier to understand, since it looks pretty much like SQL. I suppose dynamic, adhoc queries ar easier to implement in HQL too.