Buggy code:
public class ResultColumnList extends QueryTreeNodeVector { protected boolean indexRow ; protected long conglomerateId ; int orderBySelect = 0 ; protected boolean forUpdate ; private boolean countMismatchAllowed ; private int initialListSize = 0 ; public ResultColumnList ( ) { } public void addResultColumn ( ResultColumn resultColumn ) { } public void appendResultColumns ( ResultColumnList resultColumns , boolean destructiveCopy ) { } public ResultColumn getResultColumn ( int position ) { } public ResultColumn getResultColumn ( int colNum , ResultSetNode rsn , int [ ] whichRC ) throws StandardException { } public ResultColumn getOrderByColumn ( int position ) { } public ResultColumn getResultColumn ( String columnName ) { } public ResultColumn getResultColumn ( String columnName , boolean markIfReferenced ) { } public ResultColumn getResultColumn ( String columnsTableName , String columnName ) { } public ResultColumn getAtMostOneResultColumn ( ColumnReference cr , String exposedTableName , boolean considerGeneratedColumns ) throws StandardException { } public ResultColumn getOrderByColumnToBind ( String columnName , TableName tableName , int tableNumber , OrderByColumn obc ) throws StandardException { } private void collapseVirtualColumnIdGap ( int gap ) { } public ResultColumn findResultColumnForOrderBy ( String columnName , TableName tableName ) throws StandardException { } void copyResultColumnNames ( ResultColumnList nameList ) { } public void treePrint ( int depth ) { } public void bindExpressions ( FromList fromList , SubqueryList subqueryList , Vector aggregateVector ) throws StandardException { } public void bindResultColumnsToExpressions ( ) throws StandardException { } public void bindResultColumnsByName ( TableDescriptor targetTableDescriptor ) throws StandardException { } public FormatableBitSet bindResultColumnsByName ( TableDescriptor targetTableDescriptor , DMLStatementNode statement ) throws StandardException { } public void bindResultColumnsByName ( ResultColumnList fullRCL , FromVTI targetVTI , DMLStatementNode statement ) throws StandardException { } public void bindResultColumnsByPosition ( TableDescriptor targetTableDescriptor ) throws StandardException { } public void preprocess ( int numTables , FromList outerFromList , SubqueryList outerSubqueryList , PredicateList outerPredicateList ) throws StandardException { } void checkStorableExpressions ( ResultColumnList toStore ) throws StandardException { } public int [ ] getStreamStorableColIds ( int heapColCount ) throws StandardException { } void checkStorableExpressions ( ) throws StandardException { } public void generate ( ActivationClassBuilder acb , MethodBuilder mb ) throws StandardException { } void generateNulls ( ActivationClassBuilder acb , MethodBuilder mb ) throws StandardException { } void generateCore ( ExpressionClassBuilder acb , MethodBuilder mb , boolean genNulls ) throws StandardException { } public ExecRow buildEmptyRow ( ) throws StandardException { } public ExecRow buildEmptyIndexRow ( TableDescriptor td , ConglomerateDescriptor cd , StoreCostController scc , DataDictionary dd ) throws StandardException { } void generateHolder ( ExpressionClassBuilder acb , MethodBuilder mb ) throws StandardException { } void generateHolder ( ExpressionClassBuilder acb , MethodBuilder mb , FormatableBitSet referencedCols , FormatableBitSet propagatedCols ) throws StandardException { } MethodBuilder generateHolderMethod ( ExpressionClassBuilder acb , FormatableBitSet referencedCols , FormatableBitSet propagatedCols ) throws StandardException { } private void genCreateRow ( ExpressionClassBuilder acb , LocalField field , String rowAllocatorMethod , String rowAllocatorType , int numCols ) throws StandardException { } public ResultColumnDescriptor [ ] makeResultDescriptors ( ) { } public void expandAllsAndNameColumns ( FromList fromList ) throws StandardException { } public void nameAllResultColumns ( ) throws StandardException { } boolean columnTypesAndLengthsMatch ( ) throws StandardException { int size = size ( ) ; for ( int index = 0 ; index < size ; index ++ ) { ResultColumn resultColumn = ( ( ResultColumn ) ( elementAt ( index ) ) ) ; <START_BUG> if ( resultColumn . isGenerated ( ) ) { <END_BUG> continue ; } if ( ! ( resultColumn . columnTypeAndLengthMatch ( ) ) ) return false ; } return true ; } boolean columnTypesAndLengthsMatch ( ResultColumnList otherRCL ) throws StandardException { } public boolean nopProjection ( ResultColumnList childRCL ) { } public ResultColumnList copyListAndObjects ( ) throws StandardException { } public void removeOrderByColumns ( ) { } public void genVirtualColumnNodes ( ResultSetNode sourceResultSet , ResultColumnList sourceResultColumnList ) throws StandardException { } public void genVirtualColumnNodes ( ResultSetNode sourceResultSet , ResultColumnList sourceResultColumnList , boolean markReferenced ) throws StandardException { } public void adjustVirtualColumnIds ( int adjust ) { } public void doProjection ( ) throws StandardException { } public String verifyUniqueNames ( boolean errForGenCols ) throws StandardException { } public void propagateDCLInfo ( ResultColumnList derivedRCL , String tableName ) throws StandardException { } void rejectParameters ( ) throws StandardException { } void rejectXMLValues ( ) throws StandardException { } public void setResultSetNumber ( int resultSetNumber ) { } public void setRedundant ( ) { } public void checkColumnUpdateability ( String [ ] ucl , String cursorName ) throws StandardException { } public void setUnionResultExpression ( ResultColumnList otherRCL , int tableNumber , int level , String operatorName ) throws StandardException { } public boolean isExactTypeAndLengthMatch ( ResultColumnList otherRCL ) throws StandardException { } public boolean updateOverlaps ( int [ ] columns ) { } ResultColumn [ ] getSortedByPosition ( ) { } public int [ ] sortMe ( ) { } public ResultColumnList expandToAll ( TableDescriptor td , TableName tableName ) throws StandardException { } public void bindUntypedNullsToResultColumns ( ResultColumnList bindingRCL ) throws StandardException { } void markUpdated ( ) { } void markUpdatableByCursor ( ) { } public void disablePrivilegeCollection ( ) { } public String verifyCreateConstraintColumnList ( TableElementList tel ) { } public void exportNames ( String [ ] columnNames ) { } public ResultColumn findParentResultColumn ( ResultColumn childRC ) { } void markUpdated ( ResultColumnList updateColumns ) { } void markColumnsInSelectListUpdatableByCursor ( Vector updateColumns ) { } private void commonCodeForUpdatableByCursor ( Vector updateColumns , boolean dealingWithSelectResultColumnList ) { } void markUpdatableByCursor ( Vector updateColumns ) { } boolean updatableByCursor ( int columnPosition ) { } public boolean isCloneable ( ) { } public void remapColumnReferencesToExpressions ( ) throws StandardException { } void setIndexRow ( long cid , boolean forUpdate ) { } public boolean hasConsistentTypeInfo ( ) throws StandardException { } public boolean containsAllResultColumn ( ) { } public int countReferencedColumns ( ) { } public void recordColumnReferences ( int [ ] idArray , int basis ) { } public int getPosition ( String name , int basis ) { }

Fix:
if ( ( resultColumn . isGenerated ( ) ) || ( resultColumn . isGeneratedForUnmatchedColumnInInsert ( ) ) ) {