Program: 95963
Project: 95963
Buggy source:
@Test public void testTpch1() throws VerdictDBException, SQLException {
  String sql="String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str";
  stmt.execute("String_Node_Str");
  SelectQueryCoordinator coordinator=new SelectQueryCoordinator(new JdbcConnection(conn,new MysqlSyntax()));
  coordinator.setScrambleMetaSet(meta);
  coordinator.setDefaultSchema("String_Node_Str");
  ExecutionResultReader reader=coordinator.process(sql);
  NonValidatingSQLParser sqlToRelation=new NonValidatingSQLParser();
  AbstractRelation relation=sqlToRelation.toRelation(sql);
  RelationStandardizer gen=new RelationStandardizer(coordinator.getStaticMetaData());
  relation=gen.standardize((SelectQuery)relation);
  SelectQueryToSql selectQueryToSql=new SelectQueryToSql(new MysqlSyntax());
  String stdQuery=selectQueryToSql.toSql(relation);
  int cnt=0;
  while (reader.hasNext()) {
    DbmsQueryResult dbmsQueryResult=reader.next();
    cnt++;
    if (cnt == 10) {
      ResultSet rs=stmt.executeQuery(stdQuery);
      while (rs.next()) {
        dbmsQueryResult.next();
        assertEquals(rs.getString(1),dbmsQueryResult.getString(0));
        assertEquals(rs.getString(2),dbmsQueryResult.getString(1));
        assertEquals(rs.getLong(3),dbmsQueryResult.getLong(2));
        assertEquals(rs.getDouble(4),dbmsQueryResult.getDouble(3),1e-5);
        assertEquals(rs.getDouble(5),dbmsQueryResult.getDouble(4),1e-5);
        assertEquals(rs.getDouble(6),dbmsQueryResult.getDouble(5),1e-5);
        assertEquals(rs.getDouble(7),dbmsQueryResult.getDouble(6),1e-5);
        assertEquals(rs.getDouble(8),dbmsQueryResult.getDouble(7),1e-5);
        assertEquals(rs.getDouble(9),dbmsQueryResult.getDouble(8),1e-5);
        assertEquals(rs.getDouble(10),dbmsQueryResult.getDouble(9),1e-5);
      }
    }
  }
  assertEquals(10,cnt);
  stmt.execute("String_Node_Str");
}

Fixed version (ground truth):
@Test public void testTpch1() throws VerdictDBException, SQLException {
  String sql="String_Node_Str" + "String_Node_Str" + "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str"+ "String_Node_Str";
  stmt.execute("String_Node_Str");
  SelectQueryCoordinator coordinator=new SelectQueryCoordinator(new JdbcConnection(conn,new MysqlSyntax()));
  coordinator.setScrambleMetaSet(meta);
  coordinator.setDefaultSchema("String_Node_Str");
  ExecutionResultReader reader=coordinator.process(sql);
  NonValidatingSQLParser sqlToRelation=new NonValidatingSQLParser();
  AbstractRelation relation=sqlToRelation.toRelation(sql);
  RelationStandardizer gen=new RelationStandardizer(coordinator.getStaticMetaData());
  relation=gen.standardize((SelectQuery)relation);
  SelectQueryToSql selectQueryToSql=new SelectQueryToSql(new MysqlSyntax());
  String stdQuery=selectQueryToSql.toSql(relation);
  int cnt=0;
  while (reader.hasNext()) {
    DbmsQueryResult dbmsQueryResult=reader.next();
    cnt++;
    if (cnt == 10) {
      ResultSet rs=stmt.executeQuery(stdQuery);
      while (rs.next()) {
        dbmsQueryResult.next();
        assertEquals(rs.getString(1),dbmsQueryResult.getString(0));
        assertEquals(rs.getString(2),dbmsQueryResult.getString(1));
        assertEquals(rs.getLong(3),dbmsQueryResult.getLong(2));
        assertEquals(rs.getDouble(4),dbmsQueryResult.getDouble(3),1e-5);
        assertEquals(rs.getDouble(5),dbmsQueryResult.getDouble(4),1e-5);
        assertEquals(rs.getDouble(6),dbmsQueryResult.getDouble(5),1e-5);
        assertEquals(rs.getDouble(7),dbmsQueryResult.getDouble(6),1e-5);
        assertEquals(rs.getDouble(8),dbmsQueryResult.getDouble(7),1e-5);
        assertEquals(rs.getDouble(9),dbmsQueryResult.getDouble(8),1e-5);
        assertEquals(rs.getDouble(10),dbmsQueryResult.getDouble(9),1e-5);
      }
    }
  }
  assertEquals(10,cnt);
  stmt.execute("String_Node_Str");
  System.out.println("String_Node_Str");
}