#Tips & Tricks

0 Followers · 317 Posts

Pieces of experience in InterSystems Technology which solve some particular problem in elegant or unusual way.

Article Kurro Lopez · Apr 14 14m read

 

As we all know, InterSystems is a great company.

Their products can be just as useful as they are complex.

Yet, our pride sometimes prevents us from admitting that we might not understand some concepts or products that InterSystems offers for us.

Today we are beginning a series of articles explaining how some of the intricate InterSystems products work, obviously simply and clearly.

In this essay, I will clarify what Machine Learning is and how to take advantage of it.... because this time, you WILL KNOW for sure what I am talking about.

0
0 0
Question PagerianDevelper · Mar 17

Is there a way to use a property of the type %Persistent class in a %ZEN.Component.page class?
Example:

// Data classClass PersistentClass Extends %Persistent
{
    Property Value As%String;
}
// Page classClass ClassName Extends%ZEN.Component.page
{
  Property TestProperty As PersistentClass
}


The problem is that when using it the described in the example.
The property can be set in a Method like this:

0
0 0
Question Colin Brough · Mar 25

Is there a generic process for "walking" the structure of a virtual document - eg an HL7 message (EnsLib.HL7.Message) or an XML document (EnsLib.EDI.XML.Document).

At least we'd want to be able to visit all "nodes" (HL7 fields or sub-fields, XML nodes) in the virtual document and be able to work out/generate the Property Path (so we could call "GetValueAt"). 

We can just about come up with something generic for HL7, since it only nests down to 4 levels within each segment, though we're using numeric Property Path's at that point rather than symbolic ones (MSH:1.3 etc).

0
0 0
Article Megumi Kakechi · Jul 18, 2024 1m read

InterSystems FAQ rubric

This can be done with TRY-CATCH:

#dim ex As%Exception.AbstractExceptionTRY {
    //Code that causes an error
  }
  CATCH ex {
     do ex.Log()
  }

If you use ^%ETN, call it from the BACK entry (BACK^%ETN).

Please also take a look at the related article: How to get application errors (^ERRORS) using a command

0
0 0
Article Brett Saviano · Dec 21, 2023 2m read

Have you ever been editing files in VS Code, but needed to check a global value or run a few ObjectScript commands? Now you can, with no setup required! If you have vscode-objectscript extension version 2.10.0 or later and are connected to InterSystems IRIS 2023.2 or later, you can now open a terminal connection to your server, regardless of where it's located.

There are three ways to open this new terminal:

1
8 1588
Article Colin Langella · Mar 11 2m read

Intro

In the process of trying to get more familiar with Objectscript I decided to try to build a general priority queue since I wasn't able to find an implementation anywhere. My though process for implementing this followed this general path.

Binary Heap

My first though to try to make this work quickly was to implement a binary heap and my first attempt at this used a multidimensional to build it. This version was relatively efficient, worked for strings/numbers natively, and worked for objects be letting the user override the comparitor.

0
0 0
Question Colin Brough · Feb 25

We have some ObjectScript code in a custom business process:

When Log Trace Events is ticked on the business process in the Production view in the management portal, the argument is obviously computed.

Our question is whether the argument is computed when Log Trace Events is not ticked? Don't want to accidentally include something in a $$$TRACE() statement that takes enough computation to make a performance difference when released to production, even though the final output is not written to the event log.

0
0 0
Article Sergio Farago · Feb 18 4m read

Hello Community:

Do you want to know how to record yourself without looking like you're speaking from a cave? Are you one of those who say you ‘don't come off well on camera’? 

Today I'm going to share with you some specific tips that I learned after several years of filming interviews for television and networks. I remind you that these are tips in case you are thinking of taking advantage of the Article Contest video bonus. However, they are tips that I'm sure you can use for presenting webinars, video calls and filmingyourself in general.

0
0 0
Article Sergio Farago · Feb 14 3m read

Hi Community,

As you may know, this year's Spanish Technical Articles contest will be in May. I am going to make a series of articles to support you in the creation of your articles, giving tips and tricks. Perhaps they will be useful for the contest you have active in this community as well.

As you may know, one of the bonuses or extra points you can receive is to add a video tutorial to your article. You may not even know how to approach this issue, no problem! I'm here to give you some tips that you can apply not only to the creation of these videos, but to any other.

0
0 0
Article Murray Oldfield · Jan 12, 2017 19m read

Hi, this post was initially written for Caché. In June 2023, I finally updated it for IRIS. If you are revisiting the post since then, the only real change is substituting Caché for IRIS! I also updated the links for IRIS documentation and fixed a few typos and grammatical errors. Enjoy :)

In this post, I show strategies for backing up InterSystems IRIS using External Backup with examples of integrating with snapshot-based solutions. Most solutions I see today are deployed on Linux on VMware, so a lot of the post shows how solutions integrate VMware snapshot technology as examples.

29
9 11883
Article Ben Schlanger · May 7 4m read

Here at InterSystems, we often deal with massive datasets of structured data. It’s not uncommon to see customers with tables spanning >100 fields and >1 billion rows, each table totaling hundred of GB of data. Now imagine joining two or three of these tables together, with a schema that wasn’t optimized for this specific use case. Just for fun, let’s say you have 10 years worth of EMR data from 20 different hospitals across your state, and you’ve been tasked with finding….   every clinician within your network      who has administered a specific drug         between the years of 2017-2019

0
0 0
Article Megumi Kakechi · Nov 7, 2024 1m read

InterSystems FAQ rubric

It can be obtained with a List query of the %SYS.Namespace class.

1. Create a routine like this:

getnsp
   set statement=##class(%SQL.Statement).%New()
   set status=statement.%PrepareClassQuery("%SYS.Namespace","List")
   set resultset=statement.%Execute()
   while resultset.%Next() {
       write resultset.%Get("Nsp"),!
   }
   quit

2. Run it in your terminal

USER>do ^getnsp
%SYS
DOCBOOK
SAMPLES
USER

The method of executing class queries introduced in this article can be applied in a variety of cases.

0
0 0
Article David Hockenbroch · Nov 5, 2024 7m read

As we keep updating our software, we often realize that we require more and more modern solutions. So far, only one major piece of our software relies on reading barcodes in documents and images. Since Cache did not have a means of reading barcodes in the past, we have always achieved our goals by using a Visual Basic 6 application. However, it is no longer an ideal solution because it is currently complicated to maintain it. IRIS also lacks this capability, but it has recently got an option that makes up for it: embedded Python!

0
0 0
Article Megumi Kakechi · Nov 14, 2024 1m read

InterSystems FAQ rubric

By default, the order of columns in a table is determined automatically by the system. To change the order, explicitly set the order for each property using the property keyword SqlColumnNumber when defining the class.

Example:

Property Name As %String [SqlColumnNumber = 2];

Please see the documentation below.

SqlColumnNumber

If you want to change the SQL table name, specify SqlTableName. If you want to change the column name (field name), specify SqlFieldName.

Both apply only to persistent classes.

0
0 0
Article Kate Lau · Oct 28, 2024 8m read

I am just writing something to share what I encountered last night, which is the IRIS 2024.3 does not comes with Python by default any more!!!

Which means that I need to install it by myself!!😅 The pros is, I can select my python version😁🤭💃 The trouble is.... at the first place.... I don't know what I should do😥. By going through the community (I am much more prefer than the official document, sorry InterSystems document team😓 ), I found the following piece 

https://docs.intersystems.com/iris20242/csp/docbook/DocBook.UI.Page.cls…

0
0 0
Article Anthony Master · Oct 17, 2024 2m read

I was working on a DTL but kept getting ERROR #5002... MAXSTRING errors. The problem was that most of the DTL GUI action steps only support the string data type when working with the segments. A %String has a limit of 3,641,144 characters and my OBX5.1 was 5,242,952 characters long as the example provided. Of course PACS admin stated ultra high quality up to and including 4K resolution files were needed, so we could not get the vendor to compress or reformat these files to compressed jpg or something similar.

0
0 0
Article David Hockenbroch · Oct 14, 2024 9m read

Many programming languages use the try-and-catch construct to handle runtime errors gracefully. If the code within the try block encounters an error, it will throw an exception to the catch block, where the error handling occurs. Today we will dive into the ObjectScript implementation of this construct and discuss some ways to clean things up.

ObjectScript Implementation Basics

To get started, we will first look at the basic structure of the try/catch block:

try{
    //some code here
}
catch ex{
    //some error handling here
}
0
0 0
Article Nicole Sun · Mar 25, 2024 7m read

In the business world, every second counts, and having high-performing applications is essential for streamlining our business processes. We understand the significance of crafting efficient algorithms, measurable through the big O notation.

Nevertheless, there are numerous strategies to boost the performance of systems built on the IRIS Data Platform. These strategies are equally crucial for optimizing overall efficiency.

Let's join the journey for a sneak peek into the tips for making IRIS Data Platform work better, where every little trick will help your applications shine.

1. Using Indexes

1
0 534
Article Chi Nguyen-Rettig · Sep 21, 2024 3m read

There are many applications for working with HL7 V2 messages, but the tools for working with XML in IRIS Management Portal and Cache Studio are limited. While plenty of external utilities and IDEs work with XML messages and even C-CDA documents, there is a compelling case for being able to test directly against the IRIS C-CDA framework. 

Testing within the IRIS environment provides the necessary context: 

0
0 0
Question Colin Brough · Sep 27, 2024

We are doing healthcare interface development.

Developers have Ensemble installed locally on their laptops - code will be developed locally then deployed to integration, test/UAT and ultimately production servers in due course.

One of the other applications we are developing around happens to utilise an Iris desktop client to a remote Iris server. We want to have the application available on the developers laptops alongside the local Ensemble instance.

✅ It appears that if we install their desktop client then install our local Ensemble server, things work.

0
0 0
Article Katherine Reid · Jul 16, 2019 1m read

There's an easy new way to add certificate authority (CA) certificates to your SSL/TLS configurations on InterSystems IRIS 2019.1 (and 2018.1.2) on Windows and Mac.  You can ask IRIS to use the operating system's certificate store by entering:

%OSCertificateStore

in the field for "File containing Trusted Certificate Authority X.509 certificate(s)".   Here's an image of how to do this in the portal:

And here's a link to the documentation which describes this.  It's in the list of options under "File containing trusted Certificate Authority certificate(s)".

5
4 1817
Question Colin Brough · Aug 30, 2024

I can START and STOP a business process via its Schedule setting.

Is it possible to change the value of another Setting in an analogous way?

I can imagine a SettingSchedule that could look like 

action:YYYY-MM-DDThh:mm:ss[,action:YYYY-MM-DDThh:mm:ss]

But rather than just START or STOP, action could be "SET Setting = value", overriding whatever the normal value is.

Is there an existing way of achieving this kind of functionality?

0
0 0