Program: 137716
Project: 137716
Buggy source:
/** 
 * create Tab0 Page content.
 * @param sform
 */
public void createTab0Page(SashForm sform){
  ModifyListener listener=new ModifyListener(){
    public void modifyText(    ModifyEvent e){
      useAutoGenQueryFlag=true;
    }
  }
;
  if (IndicatorCategoryHelper.isUserDefCount(category)) {
    tab0_count_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,20,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_count_where_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefRealValue(category)) {
    tab0_realvalue_column_var=createTextPart(sform,COLUMN_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_COLUMN));
    tab0_realvalue_column_var.addModifyListener(listener);
    tab0_realvalue_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_realvalue_where_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefFrequency(category)) {
    tab0_fre_first_var=createTextPart(sform,FIRST_COLUMN_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_FIRST_COLUMN));
    tab0_fre_first_var.addModifyListener(listener);
    tab0_fre_second_var=createTextPart(sform,SECOND_COLUMN_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_SECOND_COLUMN));
    tab0_fre_second_var.addModifyListener(listener);
    tab0_fre_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_fre_where_var.addModifyListener(listener);
    tab0_fre_groupby_var=createTextPart(sform,GROUP_BY_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_GROUP_BY));
    tab0_fre_groupby_var.addModifyListener(listener);
    tab0_fre_orderby_var=createTextPart(sform,ORDER_BY_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_ORDER_BY));
    tab0_fre_orderby_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefMatching(category)) {
    tab0_match_match_var=createTextPart(sform,MATCH_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_MATCHING));
    tab0_match_match_var.addModifyListener(listener);
    tab0_match_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_match_where_var.addModifyListener(listener);
  }
}

Fixed version (ground truth):
/** 
 * create Tab0 Page content.
 * @param sform
 */
public void createTab0Page(SashForm sform){
  ModifyListener listener=new ModifyListener(){
    public void modifyText(    ModifyEvent e){
      useAutoGenQueryFlag=true;
      int tempSelectNumber=selectTabNumber;
      if (canBeOverwriten_tab1) {
        selectTabNumber=1;
        tab1_fullSql.setText(getAutoGeneratedQuery());
        canBeOverwriten_tab1=true;
      }
      if (IndicatorCategoryHelper.isUserDefMatching(category)) {
        if (canBeOverwriten_tab2_match) {
          selectTabNumber=2;
          tab2_match_viewvalidRows.setText(getAutoGeneratedQuery());
          canBeOverwriten_tab2_match=true;
        }
        if (canBeOverwriten_tab3_match) {
          selectTabNumber=3;
          tab3_match_viewInvalidRows.setText(getAutoGeneratedQuery());
          canBeOverwriten_tab3_match=true;
        }
        if (canBeOverwriten_tab4_match) {
          selectTabNumber=4;
          tab4_match_viewValidValues.setText(getAutoGeneratedQuery());
          canBeOverwriten_tab4_match=true;
        }
        if (canBeOverwriten_tab5_match) {
          selectTabNumber=5;
          tab5_match_viewInvalidValues.setText(getAutoGeneratedQuery());
          canBeOverwriten_tab5_match=true;
        }
      }
 else {
        if (canBeOverwriten_tab2_viewRows) {
          selectTabNumber=2;
          tab2_viewRows.setText(getAutoGeneratedQuery());
          canBeOverwriten_tab2_viewRows=true;
        }
      }
      selectTabNumber=tempSelectNumber;
      useAutoGenQueryFlag=true;
    }
  }
;
  if (IndicatorCategoryHelper.isUserDefCount(category)) {
    tab0_count_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,20,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_count_where_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefRealValue(category)) {
    tab0_realvalue_column_var=createTextPart(sform,COLUMN_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_COLUMN));
    tab0_realvalue_column_var.addModifyListener(listener);
    tab0_realvalue_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_realvalue_where_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefFrequency(category)) {
    tab0_fre_first_var=createTextPart(sform,FIRST_COLUMN_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_FIRST_COLUMN));
    tab0_fre_first_var.addModifyListener(listener);
    tab0_fre_second_var=createTextPart(sform,SECOND_COLUMN_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_SECOND_COLUMN));
    tab0_fre_second_var.addModifyListener(listener);
    tab0_fre_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_fre_where_var.addModifyListener(listener);
    tab0_fre_groupby_var=createTextPart(sform,GROUP_BY_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_GROUP_BY));
    tab0_fre_groupby_var.addModifyListener(listener);
    tab0_fre_orderby_var=createTextPart(sform,ORDER_BY_TITLE,5,getVaribleFromMap(GenericSQLHandler.UDI_ORDER_BY));
    tab0_fre_orderby_var.addModifyListener(listener);
  }
 else   if (IndicatorCategoryHelper.isUserDefMatching(category)) {
    tab0_match_match_var=createTextPart(sform,MATCH_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_MATCHING));
    tab0_match_match_var.addModifyListener(listener);
    tab0_match_where_var=createTextPart(sform,WHERE_EXPRESSION_TITLE,10,getVaribleFromMap(GenericSQLHandler.UDI_WHERE));
    tab0_match_where_var.addModifyListener(listener);
  }
}