public quoteColumn ( string $name ) : string | ||
$name | string | column name |
return | string | column name with/without quotes. |
public function quoteColumn($name)
{
// TODO: quote for DB.TABLE.COLNAME
if ($this->quoteColumn) {
if (preg_match('/\\W/', $name)) {
return $name;
}
return $this->quoteIdentifier($name);
}
return $name;
}
public function buildSetClause(BaseDriver $driver, ArgumentArray $args) { $setClauses = array(); foreach ($this->sets as $col => $val) { $setClauses[] = $driver->quoteColumn($col) . " = " . $driver->deflate($val); } return ' SET ' . join(', ', $setClauses); }