record = new FieldsblobsWithBLOBs("Scott", "Jones",
generateRandomBlob(), generateRandomBlob(), null);
mapper.insert(record);
Fieldsblobs newRecord = new Fieldsblobs("Scott", "Doe");
FieldsblobsExample example = new FieldsblobsExample();
example.createCriteria().andFirstnameLike("S%");
int rows = mapper.updateByExample(newRecord, example);
assertEquals(1, rows);
List<FieldsblobsWithBLOBs> answer = mapper
.selectByExampleWithBLOBs(example);
assertEquals(1, answer.size());
FieldsblobsWithBLOBs returnedRecord = answer.get(0);
assertEquals(newRecord.getFirstname(),
returnedRecord.getFirstname());
assertEquals(newRecord.getLastname(), returnedRecord.getLastname());
assertTrue(blobsAreEqual(record.getBlob1(),
returnedRecord.getBlob1()));
assertTrue(blobsAreEqual(record.getBlob2(),
returnedRecord.getBlob2()));
} finally {