anchor.diff:              ?assertEqual(ok, close(SKey, SR7))
           end,
   
  -        SR8 = exec(SKey,query8, 100, IsSec, "select col1, col2 from def where col1 < '4' order by col2 desc;"),
  +        SR8 = exec(SKey,query8, 100, IsSec, "select col1 as c1, col2 from def where col1 < '4' order by col2 desc;"),
           ?Log("SortSpec8 ~p~n", [SR8#stmtResult.sortSpec]),
           ?Log("StmtCols8 ~p~n", [SR8#stmtResult.stmtCols]),
           ?Log("SortSpec8 ~p~n", [SR8#stmtResult.sortSpec]),
  
positive.code: fetch_close(SKey, Pid, IsSec) when is_pid(Pid) ->
      gen_server:call(Pid, {fetch_close, IsSec, SKey}).
  
  filter_and_sort(SKey, #stmtResult{stmtRef=Pid}, FilterSpec, SortSpec, IsSec) ->
      filter_and_sort(SKey, Pid, FilterSpec, SortSpec, IsSec);    
  filter_and_sort(SKey, Pid, FilterSpec, SortSpec, IsSec) when is_pid(Pid) ->
      gen_server:call(Pid, {filter_and_sort, IsSec, FilterSpec, SortSpec, SKey}).
  
  update_cursor_prepare(SKey, #stmtResult{stmtRef=Pid}, IsSec, ChangeList) ->
      update_cursor_prepare(SKey, Pid, IsSec, ChangeList);
  
negative.code:         {ok, NewSql, NewSortFun}
      catch
          _:Reason ->
              imem_meta:log_to_db(error,?MODULE,handle_call,[{reason,Reason},{filter_spec,FilterSpec},{sort_spec,SortSpec},{cols,Cols}],"filter_and_sort error"),
              {error,Reason}
      end,
      % ?Log("replace_sort result ~p~n", [Reply]),
  