anchor.diff:  -define(E116,{116,<<"Invalid option value">>}).
   
   
  --export([ write/2 					%% (Channel, KVTable)    			' resource may not exist
  -		, read/2					%% (Channel, KeyTable)   			' return empty Arraylist if none of these resources exists
  -		, readGELT/4				%% (Channel, Item, CKey1, CKey2)	  start with first key after CKey1, end with last key before CKey2
  - 		, readGT/4					%% (Channel, Item, CKey1, Limit)	' start with first key after CKey1, return Limit results or less
  - 		, delete/2					%% (Channel, KeyTable)    			' do not complain if keys do not exist
  - 		, deleteGELT/3				%% (Channel, CKey1, CKey2)			
  -		, deleteGTLT/3				%% (Channel, CKey1, CKey2)
  +-export([ write/2 		%% (Channel, KVTable)    			resource may not exist, will be created, return list of hashes 
  +		, read/2		%% (Channel, KeyTable)   			return empty Arraylist if none of these resources exists
  +		, readGELT/4	%% (Channel, Item, CKey1, CKey2)	start with first key after CKey1, end with last key before CKey2
  + 		, readGT/4		%% (Channel, Item, CKey1, Limit)	start with first key after CKey1, return Limit results or less
  + 		, delete/2		%% (Channel, KeyTable)    			do not complain if keys do not exist
  + 		, deleteGELT/3	%% (Channel, CKey1, CKey2)			delete range of keys >= CKey1
  +		, deleteGTLT/3	%% (Channel, CKey1, CKey2)			delete range of keys > CKey1
   		]).
   
   %% @doc Checks existence of interface tables by checking existence of table name atoms in atom cache
  
positive.code: 	imem_meta:write(AN,#skvhAudit{time=erlang:now(),ckey=K,cvalue=V}),	%% ToDo: wrap in transaction
  	write(Cmd, {TN,AN}, KVPairs, [Hash|Acc]).
  
  readGELT(Channel, Item, CKey1, CKey2) when is_binary(Item), is_binary(CKey1), is_binary(CKey2) ->
  	Cmd = [readGELT, Channel, Item, CKey1, CKey2],
  	readGELT(Cmd, create_check_channel(Channel), Item, io_key_to_term(CKey1), io_key_to_term(CKey2)).
  
negative.code: 	MatchFunction = {MatchHead, [{'>=', '$1', Key1}, {'<', '$1', Key2}], ['$_']},
  	{L,true} = imem_meta:select(TN, [MatchFunction]),
  	project_result(Cmd, L, Item).
  
  readGT(Channel, Item, CKey1, Limit)  when is_binary(Item), is_binary(CKey1), is_binary(Limit) ->
  	Cmd = [readGT, Channel, Item, CKey1, Limit],
  	readGT(Cmd, create_check_channel(Channel), Item, io_key_to_term(CKey1), io_key_to_term(Limit)).
  
  readGT(Cmd, {TN,_}, Item, Key1, Limit) ->
  	MatchHead = {skvhTable, '$1', '$2', '$3'},
  	MatchFunction = {MatchHead, [{'>', '$1', Key1}], ['$_']},
  	{L,_} = imem_meta:select(TN, [MatchFunction], Limit),
  	project_result(Cmd, L, Item).
  
  deleteGELT(Channel, CKey1, CKey2) when is_binary(Channel), is_binary(CKey1), is_binary(CKey2) ->
  	Cmd = [deleteGELT, Channel, CKey1, CKey2],
  	deleteGELT(Cmd, create_check_channel(Channel), io_key_to_term(CKey1), io_key_to_term(CKey2)).
  
  deleteGELT(Cmd, {TN,AN}, Key1, Key2) ->
  	MatchHead = {skvhTable, '$1', '$2', '$3'},
  	MatchFunction = {MatchHead, [{'>=', '$1', Key1}, {'<', '$1', Key2}], ['$1']},
  	{L,true} = imem_meta:select(TN, [MatchFunction]),
  	delete(Cmd, {TN,AN}, L, []).
  
  deleteGTLT(Channel, CKey1, CKey2) when is_binary(Channel), is_binary(CKey1), is_binary(CKey2) ->
  	Cmd = [deleteGTLT, Channel, CKey1, CKey2],
  	deleteGTLT(Cmd, create_check_channel(Channel), io_key_to_term(CKey1), io_key_to_term(CKey2)).
  
  deleteGTLT(Cmd, {TN,AN}, Key1, Key2) ->
  	MatchHead = {skvhTable, '$1', '$2', '$3'},
  	MatchFunction = {MatchHead, [{'>', '$1', Key1}, {'<', '$1', Key2}], ['$1']},
  	{L,true} = imem_meta:select(TN, [MatchFunction]),
  	delete(Cmd, {TN,AN}, L, []).
  
  project_result(Cmd, L, <<"key">>) ->
  	return_list(Cmd, [term_key_to_io(K) ||  #skvhTable{ckey=K} <- L]);
  