[erlang-questions] mnesia:dirty_update_counter

Sébastien Saint-Sevin seb-cl-mailist@REDACTED
Mon Mar 5 15:05:04 CET 2007


Hi list,

It seems I've found a bug regarding mnesia:dirty_update_counter(Tab, Key, Incr).
When I use the function for the first time with an Incr of 1 (Key not existing), the table is populated with a value of 0 for the key Key (1 expected) and returns 1 for NewVal (as expected).
The doc says : "If Key don't exits, a new record is created with the value Incr if it is larger than 0, otherwise it is set to 0."

Is this confirmed or did I missed something ?

Cheers,
Sébastien.

PS : erl-5.5.3 under windows XP



More information about the erlang-questions mailing list