If you plan on doing frequent searches against a specific HL7 segment/field, you can speed up the searches significantly by using Ensemble's "search tables" mechanism for adding an index for that field.

http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=...

Fields indexed in the search table are listed in the dropdown box on the message viewer search, or can be queried using SQL by joining EnsLib_HL7.SearchTable:

select msg.ID,msg.TimeCreated,
       msg.DocType,
       msgHdr.SourceConfigName,
       msgHdr.TargetConfigName,
       msg.RawContent 
from EnsLib_HL7.SearchTable srchTbl
join enslib_hl7.message msg on msg.id=srchTbl.docid 
join Ens.MessageHeader msgHdr on msgHdr.MessageBodyId=srchTbl.docid
where  (srchTbl.propid=(select propid from Ens_Config.SearchTableProp where classextent='EnsLib.HL7.SearchTable' and name='PatientSSN')
       and srchTbl.propvalue = '123-25-4612')
       and msgHdr.SourceConfigName='HL7.File.In'

It looks like this doesn't work for incoming files. I specified "%Y.txt" as the file spec for EnsLib.HL7.Service.FileService and it fails to pickup a file named "2016.txt".

It's too bad -- these time stamp strings would be perfect, but they seem to only be used when outputting files:

  • Specifying filename for files created by business operations
  • Timestamps appended when a business service archives a file

 

EnsLib.HL7.Service.FileService

Maybe someone can offer a more clever solution, but you could create a custom function that you call from the condition field in your routing rule. You would pass it the error information and it would return a boolean for whether or not to send the alert.

Internally the function would use a custom table (or global) which stores the error information and the date/time that error was last alerted. When called it would check the last seen time against a threshold and either return a false to suppress the alert or send a true and then insert/update the error in the table.

This is more of a Squirrel question so I can't offer specific steps, but on Windows, Java desktop apps are generally started by a .bat file or shortcut which include logic to find the location of the JRE. Usually this just checks if the environment variable JAVA_HOME is set, which I believe is also what Caché does. You could try hardcoding the Squirrel .bat file/shortcut to point to a different JRE.