@Test public void testIsolateReads() throws Exception {
GlobalTableStoreImpl gtsi = new GlobalTableStoreImpl(BufferManagerFactory.getStandaloneBufferManager(), RealMetadataFactory.example1Cached().getVdbMetaData(), RealMetadataFactory.example1Cached());
tempStore = gtsi.getTempTableStore();
metadata = new TempMetadataAdapter(RealMetadataFactory.example1Cached(), tempStore.getMetadataStore());
execute("create local temporary table x (e1 string, e2 integer)", new List[] {Arrays.asList(0)});
for (int i = 0; i < 300; i++) {
execute("insert into x (e2, e1) select e2, e1 from pm1.g1", new List[] {Arrays.asList(6)});
}
setupTransaction(Connection.TRANSACTION_SERIALIZABLE);
execute("select count(e1) from x", new List[] {Arrays.asList(1500)});
gtsi.updateMatViewRow("X", Arrays.asList(2l), true);
tc=null;
execute("select count(e1) from x", new List[] {Arrays.asList(1499)});
setupTransaction(Connection.TRANSACTION_SERIALIZABLE);
execute("select count(e1) from x", new List[] {Arrays.asList(1500)});
synch.afterCompletion(Status.STATUS_COMMITTED);
}