go to post Eduard Lebedyuk · Jul 22, 2023 Body tab is unrelated to XML export, Contents tab is essentially XML export.
go to post Eduard Lebedyuk · Jul 22, 2023 %FromJSON also accepts filenames: set obj = {}.%FromJSON("data.json")
go to post Eduard Lebedyuk · Jul 22, 2023 Well, you already have a null check. To check if the object is locked just try to acquire exclusive lock with no wait, so it's enough to call %AcquireLock.
go to post Eduard Lebedyuk · Jul 20, 2023 All object properties in a request or response object must extend %XML.Adaptor. Lists and arrays of streams are skipped. Private properties are skipped. MultiDimensional properties are skipped. XMLIO = "IN" properties are skipped. XMLPROJECTION = "NONE" properties are skipped.
go to post Eduard Lebedyuk · Jul 19, 2023 Is this an expected growth? Check on global growth, maybe there's something you can delete. You can mount blob storage from the cloud, but performance might (and probably would) take a hit.
go to post Eduard Lebedyuk · Jul 19, 2023 $property works with all objects, dynamic or not: >s a={"b":2} >w $property(a, "b") 2
go to post Eduard Lebedyuk · Jul 12, 2023 I usually export the entire package, but if you want subclasses run this query: SELECT Name FROM %Dictionary.ClassDefinitionQuery_SubclassOf('%Persistent') And then call $system.OBJ.ExportODL on every result.
go to post Eduard Lebedyuk · Jul 12, 2023 Check Security.Services class. set p("Enabled")=1 set sc = ##class(Security.Services).Modify("%Service_Telnet", .p)
go to post Eduard Lebedyuk · Jul 12, 2023 Check this example. It iterates all JSON elements, and also outputs the corresponding paths to access them.
go to post Eduard Lebedyuk · Jul 12, 2023 For DTLs, if a property name starts from %% - it would be skipped.
go to post Eduard Lebedyuk · Jul 6, 2023 Use $zdth to convert unixtime into horolog and then $zdate to convert it to date string: write $zd($zdth(572486400, -2),3) 1988-02-22
go to post Eduard Lebedyuk · Jun 27, 2023 Before you quit the onrequest method do this: Set sc = pResponse.%Save() Set ^dbg($i(^dbg)) = $lb($h, sc, pResponse.%Id()) Then check ^dbg global, sc must be 1 and there should be an id. Try to open pResponse object from a terminal.
go to post Eduard Lebedyuk · Jun 26, 2023 You need to do either: Send request to your BO in a sync mode. Wait for your async request to complete. You're sending request in async mode and don't wait for a response that's why response is not recorded - there's nothing waiting for it.
go to post Eduard Lebedyuk · Jun 22, 2023 Set image.Prompt = "Two cats with a hat reading a comic" Come on, why wouldn't you post the results?
go to post Eduard Lebedyuk · Jun 21, 2023 Why will this only work in Chrome and not Microsoft Edge? Is that a local server? Edge does not allow websockets on localhost. In the Edge open About:flags page. Enable the "allow Localhost Loopback" feature.
go to post Eduard Lebedyuk · Jun 20, 2023 Can you show the definition for /terminalsocket web app please? If it's a DEV server, add %ALL to it and check if it works. Also, check Audit DB for PROTECT errors.
go to post Eduard Lebedyuk · Jun 20, 2023 UPD: Never mind, that's the wrong answer as it's about HL7. Sorry about that. There are two ways to do that: Use EnsLib.MsgRouter.VDocRoutingEngine, it has Validation setting which is a string specifying types of validation to perform. Set to 1 to block documents that don't pass default validation. Default validation checks for DocType assignment and successful BuildMapStatus. This is equivalent to 'dm': 'd' - require DocType 'm' - require successful BuildMap status. Set to 0 to skip validation. In addition configure Bad Message Handler setting to handle messages which fail validation. I'm not sure it your messages would fail BuildMap validation, but that's the easiest option to implement. Create a subclass of EnsLib.MsgRouter.RoutingEngine and implement OnValidate method to provide custom validation. You'll also need to add Validation property to settings, same as EnsLib.MsgRouter.VDocRoutingEngine does. In OnValidate method you can perform any checks you like.
go to post Eduard Lebedyuk · Jun 20, 2023 Do you want to job ObjectScript code? Write a wrapper class method and call it from embedded python.