瀏覽代碼

HPCC-20894 HThor: Allow output to dynamic filename within APPLY()

Signed-off-by: Gavin Halliday <gavin.halliday@lexisnexis.com>
Gavin Halliday 5 年之前
父節點
當前提交
9058cf4def
共有 2 個文件被更改,包括 7 次插入0 次删除
  1. 2 0
      ecl/hthor/hthor.cpp
  2. 5 0
      ecl/regress/issue20894.ecl

+ 2 - 0
ecl/hthor/hthor.cpp

@@ -436,6 +436,8 @@ void CHThorDiskWriteActivity::stop()
     if(clusterHandler)
         clusterHandler->finish(file);
     CHThorActivityBase::stop();
+    if (helper.getFlags() & TDXvarfilename)
+        filename.clear();
 }
 
 void CHThorDiskWriteActivity::resolve()

+ 5 - 0
ecl/regress/issue20894.ecl

@@ -0,0 +1,5 @@
+layout := { STRING letter; };
+
+ds := DATASET([{'A'},{'B'},{'C'}], layout);
+
+APPLY(ds, OUTPUT(DATASET([letter],layout),,'~temp::letters::'+letter, OVERWRITE));