public function update($table, $records, $where = array(), $limit = 0) {
        $this->sql = sprintf("UPDATE `%s` SET %s %s%s;", SafeString::makeSafe($table), $this->fields($records), $this->where($where), $this->limit($limit));
        $this->executeQuery(false);
        return $this->numRows() ? true : false;
    }
public function update($table, $records, $where = array(), $limit = 0) {
        $this->sql = sprintf("UPDATE `%s` SET %s %s%s;", SafeString::makeSafe($table), $this->fields($records), $this->where($where), $this->limit($limit));
        $this->executeQuery(false);
        return $this->numRows() ? true : false;
    }
public function update ( $ table , $ records , $ where = array ( ) , $ limit = 0 ) { $ this -> sql = sprintf ( "UPDATE `%s` SET %s %s%s;" , SafeString :: makeSafe ( $ table ) , $ this -> fields ( $ records ) , $ this -> where ( $ where ) , $ this -> limit ( $ limit ) ) ; $ this -> executeQuery ( false ) ; return $ this -> numRows ( ) ? true : false ; }
Updates values in a database using the provide variables
@param string $table This should be the table you wish to update the values for
@param array $records This should be the field names and new values in the format of array('fieldname' => 'newvalue', 'fieldname2' => 'newvalue2', etc.)
@param array $where Should be the field names and values you wish to update in the form of an array e.g. array('fieldname' => 'value', 'fieldname2' => 'value2', etc).
@param int $limit The number of results you want to return 0 is default and will update all results that match the query, else should be formated as a standard integer
@return boolean Returns true if update is successful else returns false
Updates values in a database using the provide variables