Restricts a dynamic column or constraint name to safe characters.
Only keeps alphanumeric and underscores.
$field: The field name to escape.
The escaped field name as a string.
function db_escape_field($field) {
return Database::getConnection()
->escapeField($field);
}