-module(test3).

db_up(Tab, Key) ->
    db_up(val({Tab, ok}), Tab, Key).
db_erase(Tab, Key) -> delete(Tab, Key), ok;
db_erase(Tab, Key) -> d:delete(Tab, Key).

db_del(Tab, Pat, Obj) ->
    db_del(val({Tab, Obj}), Tab, Pat).
db_match(Tab, Pat) -> match(Tab, Pat), ok;
db_match(Tab, Pat) -> d:match(Tab, Pat).
