diff --git a/includes/kohana/modules/database/classes/kohana/database/query/builder.php b/includes/kohana/modules/database/classes/kohana/database/query/builder.php index 8d36e790..bb55a595 100644 --- a/includes/kohana/modules/database/classes/kohana/database/query/builder.php +++ b/includes/kohana/modules/database/classes/kohana/database/query/builder.php @@ -114,6 +114,11 @@ abstract class Kohana_Database_Query_Builder extends Database_Query { { $value = $db->quote($value); } + elseif (is_string($value) AND preg_match('/^=/',$value)) + { + // Value is a column + $value = $db->quote_column(preg_replace('/^=/','',$value)); + } elseif ((is_string($value) AND array_key_exists($value, $this->_parameters)) === FALSE) { // Quote the value, it is not a parameter