title: Erlang starting with Mnesia, write Issues
body: <p>I'm having some issue inserting data in a Mnesia database.</p>
  
  <p>Here's the code : (schema already exists)</p>
  
  <pre><code>-module(mnesia_test).
  
  -record(messages_queue, {id, ack, order, message}).
  
  -export([start/0, add/0]).
  
  start() -&gt;
      mnesia:start(),
      mnesia:delete_table(messages_queue),
      mnesia:create_table(messages_queue, [{attributes, record_info(fields, messages_queue)}, {type, bag}, {record_name, messages_queue}]).
  
  add() -&gt;
      M = #messages_queue{id = "11223344", ack = [0, 5, 32, 91, 23, 106], order= 0, message="Hello world !"},
      mnesia:write(M).
  </code></pre>
  
  <p>The write get's aborted : </p>
  
  <pre><code>Erlang R16B (erts-5.10.1) [source] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false]
  
  Eshell V5.10.1  (abort with ^G)
  1&gt; mnesia_test:start().
  {atomic,ok}
  2&gt; mnesia_test:add().
  ** exception exit: {aborted,no_transaction}
       in function  mnesia:abort/1 (mnesia.erl, line 309)
  </code></pre>