[erlang-questions] ets:select_delete problem

Mike Oxford <>
Sat Nov 12 00:56:00 CET 2011


ets:select_delete() does not work for me.

The match spec works in ets:select() and ets:select_count().

It IS coded to return the atom true as required.

ets:select(json_in_stats, [{{'$1','$2'},[],['$$']}]).
[[63488274842,1]]

ets:select(json_in_stats, [{{'$1','$2'},[],[true]}]).
[true]

ets:select_count(json_in_stats, [{{'$1','$2'},[],[true]}]).
1

ets:select_delete(json_in_stats, [{{'$1','$2'},[],[true]}]).
** exception error: bad argument
     in function  ets:select_delete/2
        called as ets:select_delete(json_in_stats,[{{'$1','$2'},[],[true]}])

What am I doing wrong?

-mox



More information about the erlang-questions mailing list