public void testPKBlobsUpdateByPrimaryKeySelective() {
PkblobsDAO dao = getPkblobsDAO();
try {
PkblobsWithBLOBs record = new PkblobsWithBLOBs();
record.setId(new Integer(3));
record.setBlob1(TestUtilities.generateRandomBlob());
record.setBlob2(TestUtilities.generateRandomBlob());
dao.insert(record);
PkblobsWithBLOBs newRecord = new PkblobsWithBLOBs();
newRecord.setId(new Integer(3));
newRecord.setBlob2(TestUtilities.generateRandomBlob());
dao.updateByPrimaryKeySelective(newRecord);
PkblobsKey key = new PkblobsKey();
key.setId(new Integer(3));
PkblobsWithBLOBs returnedRecord = dao.selectByPrimaryKey(key);
assertNotNull(returnedRecord);
assertEquals(record.getId(), returnedRecord.getId());
assertTrue(TestUtilities.blobsAreEqual(record.getBlob1(), returnedRecord
.getBlob1()));
assertTrue(TestUtilities.blobsAreEqual(newRecord.getBlob2(), returnedRecord
.getBlob2()));
} catch (SQLException e) {
fail(e.getMessage());
}
}