eclipselink - How do I delete all JPA entities? -


in testing code need have blank/empty database @ each method. there code achieve that, call in @before of test?

actually can use jpql,

em    .createquery("delete myentity m")    .executeupdate() ; 

but note, there no grants entity cache cleaned also. unit-test purposes solution.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -