If I set %session.Preserve=1 in OnPreWebMethod and I set a variable in my service method, why don't I see the variable in the CSP session processes' variables after I call the method?
This article created as side effect of preparations to the longer set of articles about simple, but still handy MapReduce implementation in Caché. I was looking for relatively easy way to pass arguments to (potentially) multiple targets via remote calling facilities. And after several attempts I have realized that we do have very powerful mechanism in the Caché ObjectScript which might be of particular help here – dynamic dispatch for methods and properties.
I am new to Cache and I am trying to convert a JSON string (msgdata) that contains a JSON payload to an object to be saved into a Driver. Entity table. I am running into 2 issues and would appreciate any help:
1) It seems that when the 1st element of a list within the payload (Choices) is an empty string, after I call %ConvertJSONToObject, the obj.%data("payload").Choices contains just 1 empty element, removing the next 3 valid values (10,20,30). The same does not happen if I change the input to [10,20,"",30], in this case it works correctly.
I want to add a class to my project. This class is in UDL format.
I know that there is a method: ##class(%Compiler.UDL.TextServices).SetTextFromStream. The problem is that to use this method I need to know the name of the class (including all packages) in advance. But, a class can have any name(I mean C:/source/AAA/BBB/CCC.cls, but the real name is Sample.Human.cls).
For now I found only one way to get to know the name of a class - just parse the class code and search for a word which is followed by "Class" word. Is there any better way to do that?
While Studio and Atelier are useful development interfaces, there are occasionally situations where a quick edit needs to be made to code and only terminal access is available. A useful set of tools to do this are the zload, zprint, zinsert, zremove, and zsave commands. These are abbreviated to zl, zp, zi, zr, and zs respectively. While each of these commands has its own page in documentation, this article will synthesize that information with examples to provide instruction for their combined use.
How to get XML subtree from XPATH.DOMResult object as Stream or CacheString.
Here is my classmethod. My system receives XML message which has nested structures. The requirement is to send one message at a time to the destination. I have created the XPATH document and used EvaluateExpression method and which returns XML.XPATH.Result of type DOM. I am able to read the dom and get value of the element and its text. But I am looking to send back the subtree.
I want to query the cache database for messages where a specific HL7 segment equals a specific value. Does Cache have a pipe to XML or hl7 segment query function?
I was asked about using date-based criteria in the file spec for an inbound file adapter.
It looks like the file spec field only accepts simple wildcards (*, ?), so I'm wondering if someone knows of a clever way of doing this preferably without creating a custom adapter/service class.
An example of the use case: An upstream system continually writes records to a file named with the current day's date. At midnight it opens a new file with the new day's date:
I have two pages and I am using the push and pop to go and back navigation. When I click the button forward and back in the browser, I can't navigate more between pages.
I don't know if this is the proper section to post this kind of issues, but in the learning tracks for Zen I'm not able to play the second video (Caché Demo - Part 5 - Building a Rich Web Interface with InterSystems Zen) , the player show the following error message:
I'm new to Cache and trying to follow the Using Cache Studio PDF. In section 2.4.3(Adding a Zen form) it tells you insert the following code;
<button caption="Save" o select="zenPage.saveRecord();" />
Unfortunately that code fails compilation. If you try and use the tools there is no o select option nor a select or onselect option. I was wondering if anyone has used this PDF before and knows what the correct attribute should be?
I'm wondering if there is a setting to show generated classes in Atelier, if there is, I haven't been able to locate it. I have code which is generating other classes, but am unable to locate those classes on the Server tab, but can see them when I open studio. Is there a setting I'm missing?
I have a DeepSee KPI defined based on %DeepSee.KPI following the documentation http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=.... I've then enabled the KPI on a dashboard by adding a Widget where the data source is the KPI. Currently the ability to show a Detail Listing is implemented by the call back %OnGetListingSQL. This method documents the parameter
NewBie's Corner Session 3 More Read and Write commands & Multiple commands
Welcome to NewBie's Corner, a weekly or biweekly post covering basic Caché Material.
Click on the Caché Cube in your system tray and select Terminal to try out the commands.
Write command with carriage return and line feed
When the exclamation point "!" is inserted after a Write command, a carriage return and line feed combination is produced. Note in this example, that a comma separates the exclamation point from the variable "X".
We had a major problem recently where a participant was sending unexpected data. It was not enough to throw an error or warning in the actual trace, but when examining the message in the viewer it did show the following:
Build Map Status = 'ERROR <EnsEDI>ErrMapSegUnrecog: Unrecognized Segment 4:'CON' found after segment 3 (CON)'
How can I query for these or be notified of them? This caused major ramifications but we did not notice it. I have Managed Services investigating but I want to cover all my bases.
I'm trying to calculate the percentage of the top level with the SUM function. But I don't understand the PARENT behavior. It does not work in any way!