title: C++ MySQL - Failing getting column names
body: <p>I'm trying to get the column names of my table. I'm using this code:</p>
  
  <pre><code>MYSQL_RES *res_set;
      MYSQL_ROW row;
  
      string query = "SHOW COLUMNS FROM `data`";
  
      mysql_query(this-&gt;_connect, query.c_str());
      res_set = mysql_store_result(this-&gt;_connect);
  
      if(mysql_num_rows(res_set) == 0){
          printf("&gt; error. mysql did not return any rows for the given player name.\n");
      }
  
      row = mysql_fetch_row(res_set);
  
      cout &lt;&lt; row[4];
  </code></pre>
  
  <p>The first column in the row is corrent. But the following ones(here '4') are anything else like <code>char(255)</code>.</p>
  
  <p>What am I doing wrong?</p>