// Create two objects in the database -- need something to lock
OQLQuery oql = _db.getOQLQuery("SELECT object FROM "
+ Sample.class.getName() + " object WHERE id = $1");
oql.bind(Sample.DEFAULT_ID);
enumeration = oql.execute();
if (enumeration.hasMoreElements()) {
object = (Sample) enumeration.nextElement();
LOG.debug("Retrieved object: " + object);
object.setValue1(Sample.DEFAULT_VALUE_1);
object.setValue2(Sample.DEFAULT_VALUE_2);