unique « Update « JPA Q&A





1. Saving unique reference data    forum.hibernate.org

I am attempting to save unique reference data within a mysql database. This data does not change over time, but can be added to. Is there an intelligent way of doing this in hibernate? Currently the test is to create the pojo, query by example, if it exists use that object, otherwise save it. This seems tedious especially if there's a ...