Singh Harmeet wrote:in JPA the persistence context and persistence unit have one to one relation(this is not rdbms relation) . the persistence context is used to manipulate the entities operations and persist the entities who are available in persistence context . the @PersistenceContext annotation is mostly used with JavaEE container , in which the persistence context is automatically managed by container. persistence context need the reference of persistence unit , because in the persistence unit we mention all the entities and transaction type etc . @PersistenceContext have unitName attribute to take the reference of persistence unit.