private String escapeSpecialCharacters ( final String string ) { final StringBuilder escaped = new StringBuilder ( ) ; for ( final char character : string . toCharArray ( ) ) { if ( character == ' ' || character == ' ' || character == ' ' ) { escaped . append ( ' ' ) ; } escaped . append ( character ) ; } return escaped . toString ( ) ; }
Escapes special characters which could be used in an operand of LIKE operator