Robert Cemper · Feb 23, 2022 go to post

and that's the effective code behind

Set rc=$zf(-1,cmd_" 2> """_errorfile_""" > """_outputfile_"""")

Robert Cemper · Feb 23, 2022 go to post

Why together ? ? ?  Who wants that ? ? ?   Where ? ? ?
A simple MERGE ^archive(....)=^source(....)  just doesn't maintain any index.
this was my message    

Robert Cemper · Feb 22, 2022 go to post

You have a lucky design without indices. That makes life with 2 distinct globals easy.
The archiving action maintaining the original ID could be achieved by a simple
MERGE from ^source to ^archive.  maintenance of indices could be slightly
effort requiring class methods.