title: MySQL create or alter table
body: <p>I am using MySQL 5.1 for my database and I'm sending the commands via a Java program (JBDC).
  Is there a <strong>MySQL</strong> command for creating or altering a table?
  Let's say I have a following table:</p>
  
  <pre><code>+----------+----------+
  | column_a | column_b |
  +----------+----------+
  | value_a  | value_b  |
  +----------+----------+
  </code></pre>
  
  <p>Now I want to use a command, that would add a column "column_c" if it didn't exist.
  That would result in:</p>
  
  <pre><code>+----------+----------+----------+
  | column_a | column_b | column_c |
  +----------+----------+----------+
  | value_a  | value_b  |          |
  +----------+----------+----------+
  </code></pre>
  
  <p>If the table didn't exist, it would create a <strong>new table</strong> with specified columns:</p>
  
  <pre><code>+----------+----------+----------+
  | column_a | column_b | column_c |
  +----------+----------+----------+
  </code></pre>
  
  <p>And finally, if the table had columns that weren't specified in the command, it would <strong>leave</strong> them <strong>untouched</strong>.</p>