title: Mnesia write fails
body: <p>I defined a record named <code>log</code>. I want to create an mnesia table with name <code>log_table</code>. When I try to write a record to table, I get <code>bad_type</code> error as follows:</p>
  
  <pre><code>(node1@kitt)4&gt; mnesia:create_table(log_table, [{ram_copies, [node()]}, 
                                                 {attributes, record_info(fields, log)}]).
  {atomic,ok}
  
  (node1@kitt)5&gt; mnesia:dirty_write(log_table, #log{id="hebelek"}).
  ** exception exit: {aborted,{bad_type,#log{id = "hebelek"}}}
  in function  mnesia:abort/1
  </code></pre>
  
  <p>What am I missing?</p>