Hi 

Below is my query.

```
ProgramAccess access = null;
access =  (ProgramAccess)entityManager.
    createQuery("update ProgramAccess p set p.isDeleted = 1 where p.id in (:progId)")
    .setParameter("progId", idStrArray).getResultList();

```

I am getting below exception.

```
java.lang.ClassCastException: org.hibernate.ejb.QueryImpl cannot be cast to com.sony.spe.b2b.entity.ProgramAccess 

```

Though I am casting it, why it is giving exception?