Interesting.   I did get this to work but don't believe it's calling the %iFind.Utils:Highlight method.   The reason I say this is that the method has extra parameters that don't correspond to the SQL %Fimd.Highlight SQL function.


I had seen that in the docs and have tried various flavors of it.  I am using embedded SQL in a classmethod here to do my search.   Here's the method

ClassMethod Search(pSessionId As %String, pSearchString As %String) As %Stream.GlobalCharacter
    set tTags="<span style='background-color:yellow;'>"
    SELECT %iFind.Highlight(Text , :pSearchString , '' , :tTags) into :results 
    FROM SSA_OCR.TempSearchable)
    quit results

When I try to use this, I get:

SSA>s rs=##class(SSA.OCR.TempSearchable).Search(20, "Cough")
 quit results }
<UNDEFINED>zSearch+7^SSA.OCR.TempSearchable.1 *results
SSA 2e1>w results
W results
<UNDEFINED>^SSA.OCR.TempSearchable.1 *results
SSA 2e1>w %objlasterror
0 àŠ=<CLASS DOES NOT EXIST>zApplyTransformation+6^%iFind.Utils.1”SSAŠ*^zApplyTransformation+6^%iFind.Utils.1^15d^zPrepareTransformations+27^%iFind.Filer.Basic.1^1(d^zFileIndex+33^%iFind.Filer.Basic.1^1*d^zFileIndex+8^%iFind.Filer.Semantic.1^1*d^zFileIndex+5^%iFind.Filer.Analytic.1^1"d^zHighlight+17^%iFind.Utils.1^1,e^%0JmCm3l4tudf^SSA.OCR.TempSearchable.1^41e^%0JmBuncommitted+1^SSA.OCR.TempSearchable.1^1(d^zSearch+6^SSA.OCR.TempSearchable.1^1e^^^0
SSA 2e1>d $System.OBJ.DisplayError(%objlasterror)
ERROR #5002: ObjectScript error: <CLASS DOES NOT EXIST>zApplyTransformation+6^%iFind.Utils.1
SSA 2e1>

Any thoughts on why this is erroring?


Check %SYSTEM.INetInfo.   I think it probably contains a method to serve your purpose 

The proper way to do this would be

if the %OnNew is going to error you should throw an exception-  If you did this, the thrown exception should be caught by your try/catch block that calls the %New() method.  Then in the catch block you can examine either %objlasterror or perhaps some specific error variable you create for your purposes.


Even in a http POST, url variables are found in %request.Data.  The content stream will contain the body of your post.

I'm not really familiar with this service but it looks like there's a format problem with some content field.   Maybe Telephone 

Working with customers who use Cache based products, while myself using primarily IRIS based products I have run into this difficulty more than once.

The only work-around I have found has been to manipulate the header of the export file generated by an IRIS system before importing into a Cache based system, not exactly easy or guaranteed to work.

The other option is to keep your code exported in an external code repository and then after you make fixes to the code re-deploy the changes to IRIS and Cache.

When studio opens a class, routine, or CSP file it takes out a lock.    I've seen cases where if Studio crashes the lock doesn't get removed.