We released a new version of ZPM (Package Manager)
New in ZPM 0.2.14 release:
- Publishing timeout
- Embedded vars usage in module parameters
- Package installation from Github repo
- Transaction support for install, load and publish.
See the details below.
InterSystems ObjectScript is a scripting language to operate with data using any data model of InterSystems Data Platform (Objects, Relational, Key-Value, Document, Globals) and to develop business logic for serverside applications on InterSystems Data Platform.
We released a new version of ZPM (Package Manager)
New in ZPM 0.2.14 release:
See the details below.
anyone know of a simple way to search a blob of text from a list of keywords in one fell swoop, without having to iterate through each keyword and perform an individual search? Ex.
s keywords="This,blob,text"
s text = "This is a sample blob of text"
i text[keywords w "hit"
We have a Unicode installation of Cache'. A client wants to send us documents that will be machine-read and loaded, automatically. They want to create the documents in ISO-8859-1 ("Latin-1"). We'd need to convert the text to UTF8 for our system. I saw the documentation on the $ZCONVERT function, but I didn't see this option. How should it be done?
Thanks!
Background: We have our own SQL map that predates InterSystems'. A program writes an XML file for each table map class as $system.OBJ.Export would. $system.OBJ.LoadDir loads the XML files into .cls files.
The reason is a long story, but we need to update parameter EXTENTSIZE (only) in existing classes. This does not seem to happen. As a test I used $system.OBJ.
Hi Developers!
Recently we released the updated version 0.1.3 of ObjectScript Package Manager (ZPM) which comes with the support of simplified ObjectScript sources folder structure.
What 'simplified' does mean?
Before 0.1.3 ZPM expected the following structure:
/src ---/cls - for ObjectScript classes ---/cls/package_name/class_name.cls ---/cls/package_name/class_name2.cls ---/mac - or Mac ObjectScript routines ---/mac/package_name/mac_routine.mac ---/mac/package_name/mac_routine2.mac ---/inc - for ObjectScript macro include files. ---/inc/package_name/include_file.inc
Hi Developers!
Many of you publish your InterSystems ObjectScript libraries on Open Exchange and Github.
But what do you do to ease the usage and collaboration to your project for developers?
In this article, I want to introduce the way how to introduce an easy way to launch and contribute to any ObjectScript project just by copying a standard set of files to your repository.
Let's go!
Moving over from Studio To VSCode like many other will do now the ObjectScript plugin reached version 1.0, I noticed I was missing some items in the objectscript explorer. For example when creating a Rest API using the spec first approach, 3 classes are generated, an application.impl, application.disp and application.spec class, but the disp class was missing in the Object Explorer.
As the application.disp is a generated class, for showing these classes you need to turn this on by hitting the switch on the object explorer:
.png)
There's also a switch to enable/disable System Items.
A while back I asked the developer community for a way to loop through repeatable HL7 segments and check them against a Data Lookup table within a Business Rule.
The example I got was the following...
ClassMethod GroupIDExists(pHL7Msg As EnsLib.HL7.Message, pSegment As %String, pField As %String, pLookupTable As %String) As %Boolean
{
#dim tSeg as EnsLib.HL7.Segment
set tSegCount = pHL7Msg.SegCountGet()
set i = 1
Set tFound = 0
//get new values
set tval=""
while ((i <= tSegCount) && (tval="")) {
set tSeg = pHL7Msg.GetSegmentAt(i)
if (tSeg.Name = pSegment) {
set tID = tSeg.GetValueAt(pField)
set tval= ..Lookup(pLookupTable, tID)
}
set i = i + 1
}
if (tval '= "")
{
Q 1
}
quit 0
}Is there an easy way to see if a class object has been compiled or needs to be? Or to get a list of classes that need to be compile in a particular namespace?
Hey everyone.
I have a process where I create a new %Stream.FileCharacter object, specify the filename (including it's path), write data to the stream, and then save. However for some reason, if the user account does not have write access to the directory, the %Save method is still returning true even though it was unable to actually write the file to the folder.
The location is a UNC path, and I'm wondering if this is tripping me up?
I had a challenge recently where I was asked to parse and iterate JSON to find a patient that has a forename = "Bill" and try to make the function that iterates through the code re-usable.
Being working in Healthcare there isn't much experience or demand for parsing JSON, as most of my work is HL7.
I took this on using the documentation and worked out a way to parse the JSON (see posts below for code and source data).
I've worked out how to iterate through the fields and repeating elements, however I'm having an issue quitting out upon finding a patient with the forename Bill.
Hi, folks!
Sometimes I need to schedule a task programmatically.
And in 99% I need having some class method be periodically called.
And I want to have the schedule be started by one line. As a job in crontab.
I decided to introduce such a module with iris-cron-task module.
See the details below!
In previous versions of cache I used to be able to write click on a class and get a delete class option but in this version I can not find the delete class option was wondering if there is another way to delete a class if you wanted to do some house keeping.
N.B. These are the classes I create not the ones that comes with cache.
I have a quick question regarding swizzled objects.
I have an original object, say Object a, I am working with.
I set a property a.something.somethingother.somethingelse.myNewProperty to some value x.
Then at some point I am saving a and continuing to work with it. I assume here by saving a, I saved myNewProperty as well. (as it should work)
At some point I would like to make certain that I have correct value in my myNewProperty, so since I happen to know it's ID I
open it directly:
Set ref=##class(somethingelse).%OpenId(Id)
but when I try to look at my ref.
So now that I have figured out how to send a Page via HTTP.OutboundAdapter, I have another question. I want to use a Function that all I have to do is pass two variables and it is sent to the HTTP.OutboundAdapter I created to send the Page.
So.. If I have a class file that Extends Ens.Rule.FunctionSet, how do I force it to send a Request to my HTTP Business Operation, without having to go through a DTL, or Business Process?
Thanks
Scott
I am trying to figure out how to send a Page via a HTTP.OutboundAdapter to a URL from Ensemble.
We have a URL that I am able to pass PNo=xxxx%PMsg=xxxx as parameters to send the page to a pager.
http://xxxxx.xxxxx.xxx/Employee/Tools/Paging/SendPage.aspx?PNo=1817&PMs…
When I send the above URL through a REST client I receive a Response of "SENT".
But when I try to send it through the HTTP.OutboundAdpater I do not get a response.
.png)
Visual Studio Code is a compatible IDE for InterSystems technology!
Visit the resource guide to learn more about the VS Code IDE and how to use the ObjectScript extensions.
As a Belgian leader in developing and operating entertainment solutions in the sports betting and casino games sector, Bingoal is a dynamic and ambitious company looking for a passionate Back-End Software Engineer. Together with the IT team, you will be working to create scalable and easy to maintain software having an impact on the core of Bingoal’s activity.
We are looking for a developer with InterSystems ObjectScript Experience.
I need another set of eyes to look at the following. Instead of a Data Lookup table, I wanted to try to lookup a value against a Cache table that I had build. So I thought I could write a function to run a simple SQL query against the Cache Table and return me a %Boolean value back to my routing rule. However today I found that it was not working properly.
Can someone take a look at the following method and verify that I am doing this correct?
How to implement transaction processing when using healthConnect to link external data for data operation
Hi Developers!
Here're the technology bonuses for the InterSystems Multi-Model Contest that will give you extra points in the voting:
See the details below.
Hi colleagues!
Every day Johns Hopkins University publishes new data on coronavirus COVID-19 pandemic status.
I built a simple InterSystems IRIS Analytics dashboard using InterSystems IRIS Community Edition in docker deployed on GCP Kubernetes which shows key measures of the disease outbreak.
This dashboard is an example of how information from CSV could be analyzed with IRIS Analytics and deployed to GCP Kubernetes in a form of InterSystems IRIS Community Edition.
Added the interactive map of the USA:
Built in multi model integration using InterSystems iris data platform
Solution of hospital information inquiry business
Integration of hospital information query business solutions using InterSystems IRIS data platform with built-in multiple models
### Summary:
With the gradual improvement of hospital information construction, there are more and more hospital subsystems, and more and more interfaces between systems. At the same time, the interface cost is increasing, and the management work is becoming more and more complex.
I've been trying to figure out how to use an ObjectScript class to search other classes for specific strings. To be very specific, I want to be able to search business rules to see if a particular DTL is in the rule. We have some orphaned DTL's in our Ensemble productions and I want to make sure that they're not being used.
Thanks.
Hi, I am a novice. how run main method by stdio -> objectscript?
Class test.TestClass Extends %Persistent
{
// main
Method Main()
{
//how run main method
}
}
Sometimes it is necessary to execute commands from the shell of the host operating system, where your ObjectScript program is located, to launch programs, operating system services, schedule crontasks, among other activities. For this, the language has a utility procedure called $ZF(-100). See:
$ZF(-100,flags,program,args)
Where flags is the type of command you want to execute. In our case, the flag is "/ SHELL", to execute shell commands on the host operating system.
Program is the name of the program or service to be executed.
Args are execution arguments passed to the program.
Hi InterSystems Community!
The ObjectScript language of InterSystems IRIS has the ability to extend classes using a very interesting feature called XData.
It is a section in your class that can be used to create custom definitions to be used within the class itself and also externally.
To create one or more XData definitions for your class is very easy, see the example:
Hi community,
How Can I get a list fo the classes from a package and for each item of the list the XData content?
Hi,
I'm trying to read a TIF file using ObjectScript.
I know that it is possible to achieve using python or R, but I don't know how to do it using ObjectScript.
If anyone has done it before and has some advice, I really appreciate it.
Best Regards,
Henrique
Tiny web application that allows you to anonymize CSV files. Based on InterSystems IRIS®
Version: store/intersystems/iris-community:2020.3.0.221.0
Sample CSV where Date of Birth and Sex will remain untouched, while the rest should be anonymized.

The application recognizes the header columns and allows the user to chose which ones to ignore.
After processing.
Make sure you have Docker up and running before starting.
Recommended in case you just want to get the application up and running.