public static final void appendValueToSql ( StringBuilder sql , Object value ) { if ( value == null ) { sql . append ( "NULL" ) ; } else if ( value instanceof Boolean ) { Boolean bool = ( Boolean ) value ; if ( bool ) { sql . append ( ' ' ) ; } else { sql . append ( ' ' ) ; } } else { appendEscapedSQLString ( sql , value . toString ( ) ) ; } }
Appends an Object to an SQL string with the proper escaping etc .