NewBie's Corner Session 28 Various Methods to Traverse a Global
Welcome to NewBie's Corner, a weekly or biweekly post covering basic Caché Material.
Judging from the number of responses to Session 27 Traversing A Global, developers are passionate about their methods. I am not here to judge the merit of the various methods.
Over the next few pages I will demonstrate a number of methods to Traverse a Global. If you don't already have a favorite they may help you pick one.
I found one interesting moment in Cache Object Script. It doesn't have(or at least I didn't find) trimming function. By trimming I mean if a string has some whitespaces/tabs/carriage returns from very beginning or/and from very right, this function removes them.
I saw someone recently refer to ECP as magic. It certainly seems so, and there is a lot of very clever engineering to make it work. But the following sequence of diagrams is a simple view of how data is retrieved and used across a distributed architecture.
It appears latest version of field test supports Rules. What does support of Ensemble rules in Atelier mean for Ensemble users? Does it mean compilation and development can now be done in new Studio? If yes, how indentation and aliment work with Atelier?
The article is a step by step guide for beginners to learn how to build a RESTful web service consumer (or client) in Ensemble. The provider can be any RESTful service, but the example is based on the service we made during the previous sessions.
Outlined below is an example of how to check if a directory exists:
Set directoryName="c:\temp\nosuchdir"
/* Check for existence of a directory - Return Value: 0 - directory does not exist; 1 - directory does exist */
Set directoryExists=##class(%File).DirectoryExists(directoryName)
If ('directoryExists) // do the processing for when a directory does not exist
Outlined below is an example of how to check if a file exists:
How do I change my login information for Cache Studio if I clicked the checkbox to automatically save my login info so I do not have to enter my username/password every time I open Studio?
We're creating a series of RESTful APIs that output data from a Cache database (made up of global storage that we've mapped to classes). I'm running into some problems with object-to-JSON conversions when relationships are involved. Eg:
ParentClass has children relationship to ChildClass
I have a question on working with dev and prod environments.
After project is ready and signed, I usually migrate outcome to production using the export tool from the studio.
For changes/adding to existing projects, I exclude the production class (as it has some different values differing the dev from the live) and I add the differences manually afterwards.
My questions on migrating are:
Does anyone has (to share) his/her best practice steps on "migrating dev to prod"?
InterSystems created this video as a high-level overview of OAuth 2.0 technology, geared toward developers looking to learn the basics of OAuth 2.0. It will teach you how OAuth 2.0 works, what roles are involved, what benefits it can provide, and how InterSystems Caché can be used with this technology.
I need to do an UPDATE via SQL and I would like the statement to return the `ID` column of each row that is updated. MS SQL has an "OUTPUT" statement, but I don't see anything similar in Cache. Is there a way to do this?
We are using object EnsLib.EDI.XML.Document and the method OutputToString -- ( context.XMLObject.OutputToString("C(utf-8)") ), In the string that we get back, Hebrew characters are unknown and we get question mark instead.
Cross-origin Resource Sharing (CORS) is one of the basic security features built into browsers. CORS controls accessing resources from a HTML page in domains other than the original domain. It is particularly important for AJAX calls. Since RESTful services can be used as data provider to any AJAX call, you have to be able to control cross-origin access. By default services are not allowed to do CORS. You are going to learn how to enable it for Ensemble RESTful services.
We are Using Ensemble 2014, Windows Server 2012 64 bit operating System.
We need to sense whether Htpps is alive or not.
In Cache we tried %HttpsRequest Library we set https property and port=443. But it doesn't work.
Anyone help us plz.
We're developing Ensemble PoC and one day our frontend developer (who doesn't have Ensemble production running) said that Populate just doesn't cut it and he needs to see the real data. He needed only one object, but the problem was - it's a big object. Still, I checked ids of everything related and wrote this command (parts omitted, but you get the idea):
I know per documentation (pasted below) to set the DSTIME parameters for the base class of a cube. If that base class has a property that is another class, do I have to add the DSTIME parameters to that secondary class?
Documentation says the following in a section titled "Enabling Cube Synchronization:"
Before you can synchronize a cube, you must enable the cube synchronization feature for that cube. To do so: