Buggy code:
private String fetchPlan ; private volatile boolean executing ; private boolean fullySortedByIndex = false ; private LOCKING_STRATEGY lockingStrategy = LOCKING_STRATEGY . DEFAULT ; private boolean parallel = false ; private Lock parallelLock = new ReentrantLock ( ) ; private Set < ORID > uniqueResult ; private boolean noCache = false ; private int tipLimitThreshold = QUERY_LIMIT_THRESHOLD_TIP . getValueAsInteger ( ) ; private final class IndexUsageLog { OIndex < ? > index ; List < Object > keyParams ; OIndexDefinition indexDefinition ; IndexUsageLog ( OIndex < ? > index , List < Object > keyParams , OIndexDefinition indexDefinition ) { } } private final class IndexComparator implements Comparator < OIndex < ? > > { public int compare ( final OIndex < ? > indexOne , final OIndex < ? > indexTwo ) { } } private static Object getIndexKey ( final OIndexDefinition indexDefinition , Object value , OCommandContext context ) { } private static ODocument createIndexEntryAsDocument ( final Object iKey , final OIdentifiable iValue ) { } public OCommandExecutorSQLSelect parse ( final OCommandRequest iRequest ) { } public Set < String > getInvolvedClusters ( ) { } public boolean isAnyFunctionAggregates ( ) { } public Iterator < OIdentifiable > iterator ( ) { } public Iterator < OIdentifiable > iterator ( final Map < Object , Object > iArgs ) { } public Object execute ( final Map < Object , Object > iArgs ) { } public Map < String , Object > getProjections ( ) { } @ Override public String getSyntax ( ) { } public String getFetchPlan ( ) { } protected void executeSearch ( final Map < Object , Object > iArgs ) { } @ Override protected boolean assignTarget ( Map < Object , Object > iArgs ) { } protected boolean executeSearchRecord ( final OIdentifiable id ) { } protected boolean handleResult ( final OIdentifiable iRecord ) { } protected int getTemporaryRIDCounter ( ) { } protected boolean addResult ( OIdentifiable iRecord ) { } protected void reportTip ( final String iMessage ) { } protected ORuntimeResult getProjectionGroup ( final Object fieldValue ) { } protected void parseGroupBy ( ) { } protected void parseOrderBy ( ) { } @ Override protected void searchInClasses ( ) { } protected int parseProjections ( ) { if ( ! ( parserOptionalKeyword ( OCommandExecutorSQLSelect . KEYWORD_SELECT ) ) ) return - 1 ; int upperBound = OStringSerializerHelper . getLowerIndexOfKeywords ( parserTextUpperCase , parserGetCurrentPosition ( ) , KEYWORD_FROM , KEYWORD_LET ) ; if ( upperBound == ( - 1 ) ) upperBound = parserText . length ( ) ; int lastRealPositionProjection = - 1 ; int currPos = parserGetCurrentPosition ( ) ; if ( currPos == ( - 1 ) ) return - 1 ; final String projectionString = parserText . substring ( currPos , upperBound ) ; if ( ( projectionString . trim ( ) . length ( ) ) > 0 ) { projections = new LinkedHashMap < String , Object > ( ) ; projectionDefinition = new LinkedHashMap < String , String > ( ) ; final List < String > items = OStringSerializerHelper . smartSplit ( projectionString , ',' ) ; int endPos ; for ( String projectionItem : items ) { String projection = OStringSerializerHelper . smartTrim ( projectionItem . trim ( ) , true , true ) ; if ( ( projectionDefinition ) == null ) throw new OCommandSQLParsingException ( "Projection<seq2seq4repair_space>not<seq2seq4repair_space>allowed<seq2seq4repair_space>with<seq2seq4repair_space>FLATTEN()<seq2seq4repair_space>and<seq2seq4repair_space>EXPAND()<seq2seq4repair_space>operators" ) ; <START_BUG> final List < String > words = OStringSerializerHelper . smartSplit ( projection , '<seq2seq4repair_space>' ) ; <END_BUG> String fieldName ; if ( ( ( words . size ( ) ) > 1 ) && ( words . get ( 1 ) . trim ( ) . equalsIgnoreCase ( OCommandExecutorSQLSelect . KEYWORD_AS ) ) ) { if ( ( words . size ( ) ) < 3 ) throw new OCommandSQLParsingException ( "Found<seq2seq4repair_space>'AS'<seq2seq4repair_space>without<seq2seq4repair_space>alias" ) ; fieldName = words . get ( 2 ) . trim ( ) ; if ( projectionDefinition . containsKey ( fieldName ) ) throw new OCommandSQLParsingException ( ( ( "Field<seq2seq4repair_space>'" + fieldName ) + "'<seq2seq4repair_space>is<seq2seq4repair_space>duplicated<seq2seq4repair_space>in<seq2seq4repair_space>current<seq2seq4repair_space>SELECT,<seq2seq4repair_space>choose<seq2seq4repair_space>a<seq2seq4repair_space>different<seq2seq4repair_space>name" ) ) ; projection = words . get ( 0 ) . trim ( ) ; if ( ( words . size ( ) ) > 3 ) lastRealPositionProjection = projectionString . indexOf ( words . get ( 3 ) ) ; else lastRealPositionProjection += ( projectionItem . length ( ) ) + 1 ; } else { projection = words . get ( 0 ) ; fieldName = projection ; lastRealPositionProjection = ( ( projectionString . indexOf ( fieldName ) ) + ( fieldName . length ( ) ) ) + 1 ; if ( ( fieldName . charAt ( 0 ) ) == '@' ) fieldName = fieldName . substring ( 1 ) ; endPos = extractProjectionNameSubstringEndPosition ( fieldName ) ; if ( endPos > ( - 1 ) ) fieldName = fieldName . substring ( 0 , endPos ) ; for ( int fieldIndex = 2 ; projectionDefinition . containsKey ( fieldName ) ; ++ fieldIndex ) fieldName += fieldIndex ; } final String p = upperCase ( projection ) ; if ( ( p . startsWith ( "FLATTEN(" ) ) || ( p . startsWith ( "EXPAND(" ) ) ) { if ( p . startsWith ( "FLATTEN(" ) ) OLogManager . instance ( ) . debug ( this , "FLATTEN()<seq2seq4repair_space>operator<seq2seq4repair_space>has<seq2seq4repair_space>been<seq2seq4repair_space>replaced<seq2seq4repair_space>by<seq2seq4repair_space>EXPAND()" ) ; List < String > pars = OStringSerializerHelper . getParameters ( projection ) ; if ( ( pars . size ( ) ) != 1 ) throw new OCommandSQLParsingException ( "EXPAND//FLATTEN<seq2seq4repair_space>operators<seq2seq4repair_space>expects<seq2seq4repair_space>the<seq2seq4repair_space>field<seq2seq4repair_space>name<seq2seq4repair_space>as<seq2seq4repair_space>parameter.<seq2seq4repair_space>Example<seq2seq4repair_space>EXPAND(<seq2seq4repair_space>out<seq2seq4repair_space>)" ) ; expandTarget = OSQLHelper . parseValue ( this , pars . get ( 0 ) . trim ( ) , context ) ; projectionDefinition = null ; projections = null ; if ( ( ( ( groupedResult ) == null ) && ( ( expandTarget ) instanceof OSQLFunctionRuntime ) ) && ( ( ( OSQLFunctionRuntime ) ( expandTarget ) ) . aggregateResults ( ) ) ) getProjectionGroup ( null ) ;

Fix:
final List < String > words = OStringSerializerHelper . smartSplit ( projection , new char [ ] { '<seq2seq4repair_space>' , '\n' , '\b' } ) ;