In my previous article, Using LIKE with Variables and Patterns in SQL, we explored how the LIKE predicate behaves in different scenarios, from Embedded SQL to Dynamic SQL, and what happens to performance when wildcards and variables come into play. That piece was about getting comfortable writing a working LIKE query. But writing SQL that works is only the starting point. To build applications that are reliable, scalable, and secure, you need to understand the best practices that underpin all SQL, including queries that use LIKE.
The August Article Bounty on the Global Masters article caught my attention, and one of the proposed topics sounded quite interesting in regard to its future use in my teaching. So, here's what I'd like to tell my students about tables in IRIS and how they correlate with the object model.
Over the years, I’ve noticed that certain SQL questions come up repeatedly on the InterSystems Developer Community, especially about using the LIKE predicate in different contexts. Common variations include:
and many more derivatives. So, I decided to write an article that focuses on how LIKE works in InterSystems IRIS SQL, especially when used with variables in Embedded SQL, Dynamic SQL, and Class Queries, while touching on pattern escaping and special character searches.
If you like Java and have a thriving Java ecosystem at work into which you need to incorporate IRIS, it's not a problem. Java External Language Gateway will do it seamlessly, almost. This gateway serves as a bridge between Java and Object Script in IRIS. You can create objects of Java classes in IRIS and call their methods. You just need a jar file to do this.
One good thing about COVID-19 is that it taught people that online work and study are possible. I remember a week before the lockdown started, everyone said that working online was impossible, not secure, etc. And what do you know, it all became possible and "secure" in the blink of an eye. As with everything, it depends on whether a person is capable of organizing his or her day and their work or study attitude. Thus, I became a great believer in online education. As an associate professor who teaches databases, I find it beneficial to my schedule and students. One thing that studying online
Hi Community!
I was recently asked my opinion of the GitHub Copilot. Since I haven't tried it myself, I decided to do some research 😀 And what better place to do it other than on the Developer Community 😜
Columnar storage is one of the newer offers provided by InterSystems IRIS. Unlike traditional row-based storage, it optimizes query processing by storing data in columns rather than rows, enabling faster access and retrieval of relevant information.
A couple of articles have been written on when it should be used to give a system the biggest boost, how to create tables like that using SQL
CREATETABLEtable (column1 type1, column2 type2, column3 type3) WITH STORAGETYPE = COLUMNAR -- ex 1CREATETABLEtable (column1 type1, column2 type2, column3 type3 WITH STORAGETYPE = COLUMNAR) -- ex 2What I find really useful about IRIS when teaching my subject of Postrelational databases is the fact that it is a multi model database. Which means that I can actually go into architecture and structure and all that only once but then show the usage of different models (like object, document, hierarchy) using the same language and approach. And it is not a huge leap to go from an object oriented programming language (like C#, Java etc) to an object oriented database.
Recently, the question came up while discussing the access to the data stored in IRIS from different languages with my students if it was possible to initiate the connection and get data from Cloud solution (InterSystems IRIS CloudSQL) from Microsoft Excel, not the other way around. Considering the many varied ways one can get data in Excel (import data from external sources, connecting to databases using ODBC drivers, using power queries and web queries etc.) the obvious choice was to try ODBC driver. The only task left was to try to connect to the database in the cloud using the ODBC driver.
Hi guys,
Apparently, I'm doing something wrong. Opened the InterSystems IRIS Cloud SQL, clicked on View Purchase Options and got an error:
Something tells me that contacting AWS customer support won't help. What should be my steps to get access to it to try it out?
We all know that having a set of proper test data before deploying an application to production is crucial for ensuring its reliability and performance. It allows to simulate real-world scenarios and identify potential issues or bugs before they impact end-users. Moreover, testing with representative data sets allows to optimize performance, identify bottlenecks, and fine-tune algorithms or processes as needed. Ultimately, having a comprehensive set of test data helps to deliver a higher quality product, reducing the likelihood of post-production issues and enhancing the overall user
Hey guys,
As the year comes to a close, it's time to reminisce a little of what's gone on and what was the most important breakthrough or discovery of this year.
Hello,
One of my students experiences a problem these last couple of days with downloading IRIS for MacOS. She gets this error message:
Where/how can she download it?
Hey guys,
I do love Global Masters (and all the rewards that I get from it) and one of my favourite activities is answering quiz questions. And just now I've had a really cute question What is the result of: WRITE "99" + "cents"? which brought a smile to my face (because I do love to add questions like this to the tests for my students). This made me think that I would really like to somehow show my appreciation to the author of this question.
Saw the other day an article with the usage of the %ZEN package when working with JSON and decided to write an article describing a more modern approach. At some recent point, there was a big switch from using %ZEN.Auxiliary.* to dedicated JSON classes. This allowed to work with JSONs more organically.
Thus, at this point there are basically 3 main classes to work with JSON:
%Library.DynamicObject- provides a simple and efficient way to encapsulate and work with standard JSON documents. Also, there is a possibility instead of writing the usual code for creating an instance of a class like
InterSystems IRIS has quite a few different kinds properties. Let’s put them in order so that they make better sense.
First of all, I would divide them into categories:
- Atomic or simple properties (all those %String, %Integer, %Data and other system or user datatypes)
- References to stored objects
- Built-in objects
- Streams (both binary and character)
- Collections (which are divided into arrays and lists)
- Relationships (one-many and parent-children)
Some of these kinds of properties are quite straightforward. For example, atomic properties:
In this tutorial, I’d like to talk about Class Queries. To be more precise, about the Queries based on user-written code:
Hello,
Created my Learning Lab yesterday evening and for the first hour or so everything was fine, but after that it just stopped working and I get Server unavailable for Management Portal:
And nothing would load in VSCode
Is there anything to be done? Because I wanted to upload my student's test on it. And the system wouldn't allow me to create another server, because I already have one.
Because I had no idea how to build an integration solution for HL7 and didn't know where to start, I decided to follow the course Building Basic HL7 Integrations with InterSystems on Learning portal to get at least the idea of where to begin. After I studied all of it, I decided it might be a good idea to share my thoughts and reflections about it with everyone.
In the previous article, we talked about the flow of data to request the test and receive the results of the requested test. Now let's talk about one of the most important messages of HL7v2 standard.
In the previous article, we've seen the structure of one of the most used types of HL7 message - ADT (Admit, Discharge, Transfer) and an example of ADT^A04 with the description of all its fields. Now let's look at another flow of data having to do with ordering and fulfilling the orders of tests. I'm talking about ORM (as of version 2.5 you should use specific messages to order tests, like OMG, OML, OMD, OMS, OMN, OMI, and OMP), ORL and ORU messages. In a very simplified case, the exchange of data may look like this.
Let's look at these messages in more detail.
A quick question. What's the shortcut to uncomment multiple lines of code in Studio? And what's the shortcut to comment out multiple lines of code in Studio?
Thanks in advance!
In the previous article, we've discussed the origin of the standard HL7v2, the structure and the types of messages. Let's now look at one of the most used types of messages and an example of its structure. I'm talking about ADT.
HL7 (Health Level 7) is a set of technical specifications for computerized exchanges of clinical, financial and administrative data between hospital information systems (HIS). These specifications are variously integrated into the corpus of formal American (ANSI) and international (ISO) standards.
Hi guys!
My student asked my why his unit tests don't work as they should, and I just could answer him. Here is the simplified case.
There is a class with a required unique property Name:
Class Test.NewClass [ Abstract ]
{
Property Name As%String [ Required ];
Index NameIndex On Name [ Unique ];
}And there is an inherited class:
Class Test.NewClass1 Extends (%Persistent, Test.NewClass)
{
}What I expect to happen, is when I save two objects of class Test.NewClass1 with the same value of property Name, for the second one to get an error stating that it violates the unique index.
Before we start talking about databases and different data models that exist, first we'd better talk about what a database is and how to use it.
A database is an organized collection of data stored and accessed electronically. It is used to store and retrieve structured, semi-structured, or raw data which is often related to a theme or activity.
At the heart of every database lies at least one model used to describe its data. And depending on the model it is based on, a database may have slightly different characteristics and store different types of data.
Hello,
I found another question on how to change the language for Studio (but it would've been nice to have my actual language used - Ukrainian, since it's available, or was available). Still, I can't seem to figure out how to get rid of gibberish in the menu without changing the Windows settings:
As you can see in my profile I teach at a university and I wanted to share my take on teaching IRIS (or Caché before it).
It’s been some time but I remember seeing a series of articles by @Yuri Marx earlier this year about the course “Developing with InterSystems Objects and SQL”. He actually gave a brief description of what’s done on Day 1, Day 2, and Day 3 with comments from instructor @Joel Solon. And I thought to myself, it may be interesting to share my experience.
The first installment of this article series discussed how to read a big chunk of data from the raw body of an HTTP POST method and save it to a database as a stream property of a class. The second installment discussed how to send files and their names wrapped in a JSON format.
In the first installment of this article series, we discussed how to read a “big” chunk of data from the raw body of an HTTP POST method and save it to a database as a stream property of a class. Now let’s look at how to save such data and metadata in JSON format.
Unfortunately, Advanced REST Client doesn’t let you compose JSON objects with binary data as a value of a key (or maybe I simply haven’t figured out how to do it), so I decided to write a simple client in ObjectScript to send data to the server.