@@ -165,13 +165,9 @@ checkcount:{[h;p;counter;td]
165165 .replay.currentcount: 0 ]}
166166
167167// function used to finish off the replay
168- // generally this will be to re-sort the table, and set an attribute
169168finishreplay : {[h ;p ;td ]
170169 // save down any tables which haven't been saved
171170 savetab [td ;h;p] each tabsincountorder [.replay.tablestoreplay ];
172- // sort data and apply the attributes
173- if [sortafterreplay ;applysortandattr [.replay.pathlist ]];
174-
175171 // invoke any user defined post replay function
176172 .save.postreplay [h;p];
177173 }
@@ -190,7 +186,7 @@ replaylog:{[logfile]
190186 [.lg.o [`replay ;"skipping first " , (string firstmessage ), " messages" ];
191187 @ [`. ;`upd ;: ;.replay.initialupd ]];
192188 @ [`. ;`upd ;: ;.replay.realupd ]];
193- .replay.tablecounts: .replay.errorcounts: .replay.pathlist : ()! ();
189+ .replay.tablecounts: .replay.errorcounts: ()! ();
194190
195191 // If not running in segmented mode, reset replay date and clean HDB directory on each loop
196192 .replay.zipped: $ [logfile like "*.gz" ;1b ;0b ];
@@ -415,7 +411,9 @@ initandrun:{
415411
416412 // Replay all logs and exit
417413 .lg.o [`initandrun ;"Replaying the following log(s): " , csv sv 1 _' string .replay.logstoreplay ];
414+ .replay.pathlist: ()! ();
418415 .replay.replaylog each .replay.logstoreplay ;
416+ if [sortafterreplay ;applysortandattr [.replay.pathlist ]];
419417 if [partandmerge ;postreplaymerge [tempdir ;.replay.replaydate ;hdbdir ]];
420418 .lg.o [`replay ;"replay complete" ];
421419 if [.replay.exitwhencomplete ;exit 0 ];
0 commit comments