taking care of LIKE when used in UPDATE statement #798
diff --git a/system/database/DB_active_rec.php b/system/database/DB_active_rec.php
index 4392077..7a608c4 100644
--- a/system/database/DB_active_rec.php
+++ b/system/database/DB_active_rec.php
@@ -1424,7 +1424,7 @@
 			$this->limit($limit);
 		}
 
-		$sql = $this->_update($this->_protect_identifiers($this->ar_from[0], TRUE, NULL, FALSE), $this->ar_set, $this->ar_where, $this->ar_orderby, $this->ar_limit);
+		$sql = $this->_update($this->_protect_identifiers($this->ar_from[0], TRUE, NULL, FALSE), $this->ar_set, $this->ar_where, $this->ar_orderby, $this->ar_limit, , $this->ar_like);
 
 		$this->_reset_write();
 		return $this->query($sql);
diff --git a/system/database/drivers/mysql/mysql_driver.php b/system/database/drivers/mysql/mysql_driver.php
index 828ef00..7952312 100644
--- a/system/database/drivers/mysql/mysql_driver.php
+++ b/system/database/drivers/mysql/mysql_driver.php
@@ -606,7 +606,7 @@
 	 * @param	array	the limit clause
 	 * @return	string
 	 */
-	function _update($table, $values, $where, $orderby = array(), $limit = FALSE)
+	function _update($table, $values, $where, $orderby = array(), $limit = FALSE, $like = array())
 	{
 		foreach ($values as $key => $val)
 		{
@@ -620,6 +620,15 @@
 		$sql = "UPDATE ".$table." SET ".implode(', ', $valstr);
 
 		$sql .= ($where != '' AND count($where) >=1) ? " WHERE ".implode(" ", $where) : '';
+		
+		if (count($like) > 0) {
+			$sql .= ($where == '' AND count($where) <1) ? " WHERE " : ' AND ';
+			foreach ($like as $st_like) {
+
+				$sql .= " " . $st_like;
+				
+			}
+		}
 
 		$sql .= $orderby.$limit;