1 database.inc | public DatabaseConnection_mysql::escapeAlias($field) |
Escapes an alias name string.
Force all alias names to be strictly alphanumeric-plus-underscore. In contrast to DatabaseConnection::escapeField() / DatabaseConnection::escapeTable(), this doesn't allow the period (".") because that is not allowed in aliases.
Parameters
string $field: The field alias to be escaped.
Return value
string: The sanitized field alias string.
Overrides DatabaseConnection::escapeAlias
File
- core/
includes/ database/ mysql/ database.inc, line 156 - Database interface code for MySQL database servers.
Class
- DatabaseConnection_mysql
- MySQL database connection driver.
Code
public function escapeAlias($field) {
$field = parent::escapeAlias($field);
return $this->quoteIdentifier($field);
}