public function update($sqlQuery = false)
    {
        $field = func_get_args();
        if(func_num_args() == 0) {
            echo 'no data to save'; //no argument
            exit;
        }
        elseif(func_num_args() == 1) {
            if(is_array($field[0])) {
                $data = $field[0]; //single array with all data
            }
            else {
                $data = $field[0]; //sql fraction
            }
        }
        else {
            echo 'invalid data';
            exit;
        }
        $sql = $this->buildQuery('update', $data);
        if($sqlQuery === true) {
            return $this->getQuery();
        }
        $result = $this->executeQuery($sql);
        return $result;
    }
public function update($sqlQuery = false)
    {
        $field = func_get_args();
        if(func_num_args() == 0) {
            echo 'no data to save'; //no argument
            exit;
        }
        elseif(func_num_args() == 1) {
            if(is_array($field[0])) {
                $data = $field[0]; //single array with all data
            }
            else {
                $data = $field[0]; //sql fraction
            }
        }
        else {
            echo 'invalid data';
            exit;
        }
        $sql = $this->buildQuery('update', $data);
        if($sqlQuery === true) {
            return $this->getQuery();
        }
        $result = $this->executeQuery($sql);
        return $result;
    }
public function update ( $ sqlQuery = false ) { $ field = func_get_args ( ) ; if ( func_num_args ( ) == 0 ) { echo 'no data to save' ; //no argument
 exit ; } elseif ( func_num_args ( ) == 1 ) { if ( is_array ( $ field [ 0 ] ) ) { $ data = $ field [ 0 ] ; //single array with all data
 } else { $ data = $ field [ 0 ] ; //sql fraction
 } } else { echo 'invalid data' ; exit ; } $ sql = $ this -> buildQuery ( 'update' , $ data ) ; if ( $ sqlQuery === true ) { return $ this -> getQuery ( ) ; } $ result = $ this -> executeQuery ( $ sql ) ; return $ result ; }
Update data to table

@param  string|null  $field
@param  string|null  $sqlQuery
@rturn  bool
Update data to table