if (sql.length() > initialLength) {
sql.append(" AND ");
}
final FieldMapping fieldMapping = fieldMappingFor(patternAssoc);
if (fieldMapping != null) {
fieldMapping.appendWhereClause(connector, sql, pattern);
} else {
// Have to use getXXX method if the fieldMapping is
// null..
final ObjectSpecification specification = patternAssoc.getSpecification();