I gues you want to use the foreign key pointing from comment to blog, but you are using the "id" (autoinc pk of comment?) instead.
session.createCriteria(Comment.class).add(Restrictions.eq("id",blog)).list(); return l; Jens Sent from my iPhone On 18.09.2012, at 03:02, Taha Siddiqi <tawus.tapes...@gmail.com> wrote: > > Should Restrictions.eq("id",blog) be Restrictions.eq("blog",blog) > > Also I would use blog as activation context in the second page. @Persist > should be avoided if possible. > > > On Sep 15, 2012, at 9:57 PM, JeffersON wrote: > >> Restrictions.eq("id",blog) >