web stats
Mirth Community - View Single Post - File Reader - force a move to error directory
View Single Post
  #1  
Old 03-27-2017, 10:40 PM
JasmeetSingh JasmeetSingh is offline
What's HL7?
 
Join Date: Nov 2012
Posts: 3
JasmeetSingh is on a distinguished road
Default File Reader - force a move to error directory

Hi,

I am using Mirth Connect Server 3.1.1.7461.

Here is what I am trying to achieve:
  1. Pick up a file using File Reader
  2. Create batches of 50 lines using javascript in Data Types
  3. If any one entry of the batch is not processed, then mark the batch as ERROR
  4. Once all batches are complete, if anyone batch is in ERROR then move the file into error directory

For point #3, I am putting following code in my transformer response:
Code:
responseStatus = ERROR;
I chose my destination name in Response drop down of source. However it is still moving files to processed folder.

I want that out of 10 batch (for example), even if one batch is failed then the file should be moved to error folder.

How can I achieve this?
Reply With Quote