title: How to update a database in phpmyAdmin using matlab?
body: <p>I wanted to update a database inside the phpmyAdmin however, an error keeps popping up and I tried many solution but still it does not work. The code:</p>
  
  <pre><code>conn=database('iprintstatuses', 'root', '', 'com.mysql.jdbc.Driver',     'jdbc:mysql://localhost/');
  setdbprefs('DataReturnFormat','cellarray');
  paper_loader_on_status = fetch(conn,'SELECT paper_loader FROM statuses');
  paper_loader = paper_loader_on_status {1};
  newz= {'1'};
  whereclause = 'where paper_loader = 1';
  if (paper_loader == 1)
      pause(1);
      update(conn, 'statuses', 'new_paper_loader', newz, whereclause);
  end
  </code></pre>
  
  <p>The error: </p>
  
  <p>Cell contents reference from a non-cell array object.</p>
  
  <p><strong>Error</strong> in database/update (line 125)</p>
  
  <pre><code>updateFields = [updateFields fieldNames{j}]; %#ok
  </code></pre>
  
  <p><strong>Error</strong> in SQLaccessing (line 10)</p>
  
  <pre><code>update(conn, 'statuses', 'new_paper_loader', newz, whereclause);
  </code></pre>
  
  <p>How to solve this error?</p>
  
  <p><a href="https://i.stack.imgur.com/nmgCL.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/nmgCL.png" alt="This is the image of the table. It is really a simple table :( *It is an integer*"></a></p>