Program: 65314
Project: 65314
Buggy source:
public void buildOROXProjects(NamingConventionTransformer nct){
  this.nct=nct;
  String projectName=dbwsBuilder.getProjectName();
  Project orProject=new Project();
  orProject.setName(projectName + "String_Node_Str" + DBWS_OR_LABEL);
  Project oxProject=null;
  if (dbTables.isEmpty() && !dbwsBuilder.hasBuildSqlOperations()) {
    dbwsBuilder.logMessage(FINEST,"String_Node_Str");
    oxProject=new SimpleXMLFormatProject();
  }
 else {
    oxProject=new Project();
  }
  oxProject.setName(projectName + "String_Node_Str" + DBWS_OX_LABEL);
  for (  TableType dbTable : dbTables) {
    String tableName=dbTable.getTableName();
    RelationalDescriptor desc=buildORDescriptor(tableName,dbwsBuilder.getProjectName(),dbwsBuilder.requireCRUDOperations,nct);
    orProject.addDescriptor(desc);
    XMLDescriptor xdesc=buildOXDescriptor(tableName,dbwsBuilder.getProjectName(),dbwsBuilder.getTargetNamespace(),nct);
    oxProject.addDescriptor(xdesc);
    for (    FieldType dbColumn : dbTable.getColumns()) {
      String columnName=dbColumn.getFieldName();
      ElementStyle style=nct.styleForElement(columnName);
      if (style == NONE) {
        continue;
      }
      dbwsBuilder.logMessage(FINE,"String_Node_Str" + tableName + "String_Node_Str"+ columnName);
      DirectToFieldMapping orFieldMapping=buildORFieldMappingFromColumn(dbColumn,desc,dbwsBuilder.getDatabasePlatform(),nct);
      desc.addMapping(orFieldMapping);
      XMLDirectMapping oxFieldMapping=buildOXFieldMappingFromColumn(dbColumn,dbwsBuilder.getDatabasePlatform(),nct);
      xdesc.addMapping(oxFieldMapping);
      if (oxFieldMapping.getAttributeClassificationName() == APBYTE.getName()) {
        orFieldMapping.setAttributeClassificationName(APBYTE.getName());
      }
    }
    setUpFindQueries(tableName,desc);
  }
  finishUpProjects(orProject,oxProject);
}

Fixed version (ground truth):
/** 
 * Builds OR/OX projects, descriptors & mappings, based on a given list of types, as well as table(s) and secondary SQL.
 */
public void buildOROXProjects(NamingConventionTransformer nct,List<CompositeDatabaseType> types){
  this.nct=nct;
  String projectName=dbwsBuilder.getProjectName();
  Project orProject=new Project();
  orProject.setName(projectName + "String_Node_Str" + DBWS_OR_LABEL);
  Project oxProject=null;
  if (dbTables.isEmpty() && !dbwsBuilder.hasBuildSqlOperations()) {
    dbwsBuilder.logMessage(FINEST,"String_Node_Str");
    oxProject=new SimpleXMLFormatProject();
  }
 else {
    oxProject=new Project();
  }
  oxProject.setName(projectName + "String_Node_Str" + DBWS_OX_LABEL);
  for (  TableType dbTable : dbTables) {
    String tableName=dbTable.getTableName();
    RelationalDescriptor desc=buildORDescriptor(tableName,dbwsBuilder.getProjectName(),dbwsBuilder.requireCRUDOperations,nct);
    orProject.addDescriptor(desc);
    XMLDescriptor xdesc=buildOXDescriptor(tableName,dbwsBuilder.getProjectName(),dbwsBuilder.getTargetNamespace(),nct);
    oxProject.addDescriptor(xdesc);
    for (    FieldType dbColumn : dbTable.getColumns()) {
      String columnName=dbColumn.getFieldName();
      ElementStyle style=nct.styleForElement(columnName);
      if (style == NONE) {
        continue;
      }
      dbwsBuilder.logMessage(FINE,"String_Node_Str" + tableName + "String_Node_Str"+ columnName);
      DirectToFieldMapping orFieldMapping=buildORFieldMappingFromColumn(dbColumn,desc,dbwsBuilder.getDatabasePlatform(),nct);
      desc.addMapping(orFieldMapping);
      XMLDirectMapping oxFieldMapping=buildOXFieldMappingFromColumn(dbColumn,dbwsBuilder.getDatabasePlatform(),nct);
      xdesc.addMapping(oxFieldMapping);
      if (oxFieldMapping.getAttributeClassificationName() == APBYTE.getName()) {
        orFieldMapping.setAttributeClassificationName(APBYTE.getName());
      }
    }
    setUpFindQueries(tableName,desc);
  }
  finishUpProjects(orProject,oxProject,types);
}