mnesia:clear_table

Ulf Wiger (AL/EAB) ulf.wiger@REDACTED
Tue Aug 16 14:01:53 CEST 2005


Serge Aleynikov wrote:
>
> If schema transaction don't support nesting, I am not sure 
> your answer clarifies why the following code should work
> if schema transaction don't support nesting:
> 
> mnesia:transaction(
>    fun() ->
>      mnesia:clear_table(test),
>    end).


But it doesn't work:

4> mnesia:create_table(test,[{ram_copies,[node()]}]).
{atomic,ok}
5> mnesia:transaction(fun() -> mnesia:clear_table(test) end).
{atomic,{aborted,nested_transaction}}

Granted, the return value is a bit funny. (:


/Uffe



More information about the erlang-questions mailing list