InterSystems IRIS is a Complete Data Platform
InterSystems IRIS gives you everything you need to capture, share, understand, and act upon your organization’s most valuable asset – your data.
As a complete platform, InterSystems IRIS eliminates the need to integrate multiple development technologies. Applications require less code, fewer system resources, and less maintenance.
Hi everyone,
I have this global with 2 informations in it: Reference (ex: 1329) and Code (ex: JMMK-G1D6).
^DataTest = 3
^DataTest(1) = $lb("","1329","JMMK-G1D6")
^DataTest(2) = $lb("","1516","AMEV-GVPF")
^DataTest(3) = $lb("","2333","4QC6-4HW3")
With ObjectScript, i want to test if Reference 1516 exists in the global.
In the InterSystems portal, i can do it with SQL (SELECT count(*) FROM DataTest where Reference = '1516'), but can we do the same in ObjectScript without SQL and manipulating the global directly ?
Thanks for help.
Hello everyone,
I'm currently working on a business operation that employs a retry mechanism with a FailureTimeout = -1. So, this BO attempts to resend the message at the end of a RetryInterval of n seconds (n is configurable).
What I would like to achieve is to set a timer that runs in parallel with the sending mechanism so that, If I don't receive a response within m seconds (m also is configurable and m<=n) from the initial message send (with RetryCount = 1), an alert or something similar is triggered.
InterSystems FAQ rubric
When you run a routine in the terminal and an error occurs in the program, if you have not set the error trap properly, the program will enter debug mode as shown below.
USER>do^error1
write A
^
a+2^error1 *A
USER 2d0>From this state, enter the Quit command to return to the state before the routine was started.
USER 2d0>QuitIf a transaction is being processed within the routine where the error occurred, a prompt similar to the one below will appear.
Hi everyone.
I have a function that may end up being called from a number of transformations at the same time, and within the function there's some Embedded SQL to first check if a local table has an entry, and then adds the entry if it doesn't exist.
To prevent a race condition where the function is called by two transformations and they both end up attempting to insert the same value, I'm looking to use the table hint "WITH TABLOCK" on the insert, but this seems to be failing the syntax checks within vscode.
Are table hints supported with embedded sql?
Hi,
I was struggling with a procedure that was meant to receive a string and use it as a filter, I've found that since I want the procedure to do some data transformation and return a dataset, I needed to use objectScript language.
Hi,
i have this simple json structure:
{
"nTypeTrigger": "ATR",
"sDate": "2024-04-17 15:29:16",
"tRefArray": [{"sID":"132"},{"sID":"151"},{"sID":"233"}],
"tCountries": []
}
I can't find an example to iterate on tRefArray.
I've tried to create a secondary iterator but it doesn't work. Here is my current code:
// extract json content from the request:
set dynRequestJsonPayload = {}.%FromJSON(%request.Content)
set JsonIterator = dynRequestJsonPayload.%GetIterator()
// iterate on json structure:
if dynRequestJsonPayload '= "" {
while JsonIterator.%GetNext(.key, .
Hello!
I wonder if anyone has a smart idea to extract an XML fragment inside a text document (incoming from a stream)?
The XML fragment is surrounded by plain text.
Example:
text...........
text...........
<?xml version="1.0" encoding="UTF-8 ?>
<Start>
...etc
</Start>
text...........
text...........
The XML is not represented by any class or object in the Namespace.
The XML can look different from time to time
Appreciated if anyone knows how to use Objectscript to extract the XML content.
Regards Michael
Hello everybody,
I've been experimenting with Embedded Python and have been following the steps outlined in this documentation: https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cl…
I'm trying to convert a python dictionary into an objectscript array but there is an issue with the 'arrayref' function, that is not working as in the linked example.
This is a snapshoot of my IRIS terminal:
USER>do##class(%SYS.Python).Shell()
Python 3.10.12 (main, Nov 202023, 15:14:05) [GCC 11.4.
Hello all, i am new to IRIS in combination with VSCode, can anyone guide why this error appears ? Any suggestions are welcome. Thank you in advance.
Hi Guys,
I'm new to IRIS and I'm converting from Ensemble 2018 to IRIS but not sure how to convert my cache.data file to IRIS.dat, I copied my cache.data to a new folder then went to IRIS management portal and created a new database and specified the directory to where my cache.data and saved and I thought that IRIS will automatically convert cache.dat to IRIS.dat but instead it created a new empty IRIS.dat, I guess I was wrong in my assumptions !?
.png)
also by leaving the New Volume Threshold size as zero is that mean that I always have only one IRIS.
Hey Community,
Play the new video on InterSystems Developers YouTube:
⏯ Unleashing the Power of Machine Learning with InterSystems @ Global Summit 2023
Spoilers: Daily Integrity Checks are not only a best practice, but they also provide a snapshot of global sizes and density.
Update 2024-04-16: As of IRIS 2024.1, Many of the below utilities now offer a mode to estimate the size with <2% error on average with orders of magnitude improvements in performance and IO requirements. I continue to urge regular Integrity Checks, however there are situations where more urgent answers are needed.
EstimatedSize^%GSIZE- Runs %GSIZE in estimation mode.##class(%Library.GlobalEdit).GetGlobalSize(directory, globalname, .allocated, .used.
With System Alerting and Monitoring (SAM) being deprecated in the near future..
- What is everyone's go-to for Monitoring IRIS?
- What is readily available?
- What is the cost surrounding it?
Just trying to get ideas floating around of what we might need to start looking at to satisfy IT leadership.
Thanks
Scott
Hello community,
in addition to HL7 V2 interfaces mediated via TCP/IP, we have been implementing more and more HS.FHIRServer.Interop.Service based services that are addressed via port 57772.
We would like to secure access to the Management Portal now and have come up with a procedure that I would like to discuss.
1. The local server firewall only allows access to port 57772 for the IPs of the administration PCs (and some few other exceptions).
2. A REST service is introduced for access to FHIR endpoints, which listens on a different (accessible) port.
What user can be used to initiate IRIS container in emergency access mode on startup?
Dear All , As per the title,
I was tasked to upgrade an old legacy system to run on Windows 11.
I am having a problem with Cache mostly.
I have the version: VERSION 5.0.14 , BUILD 5702 , OBJECTS 5.0.5702.0 I would like to know if there is a way to run it on windows 11 somehow.
I know I am asking for a LOT. Unfortunately, the provider of the suit is long gone, and I can't keep it on windows XP. Let me know if there is an alternative way to get it up to date even with the lowest / more recent version.
Thank you in advance for your time.
Hi,
I have created view from External table joins internal persistent table. Create VIEW worked but Select * from Viewxxx throwing error.
"References to an SQL connection must constitute a whole subquery"
https://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KE….
Could it possible to create view with external db table with local persistant table and to access it?
please suggest any thoughts on it..
Thanks,
Hi developers!
Just want to share an old but always relevant best practice on namespaces changing @Dmitry Maslennikov shared with me (again).
Consider method:
classmethod DoSomethingInSYS() as %Status
{
set sc=$$$OK
set ns=$namespace
zn "%SYS"
// try-catch in case there will be an error
try {
// do something, e.g. config change
}
catch {}
zn ns ; returning back to the namespace we came in the routine
return sc
}And with new $namespace the method could be rewritten as:
classmethod DoSomethingInSYS() as %Status
{
set sc=$$$OK
new $namespace
set $namespace="%SYS"
// do something
return sc
}So! The difference is that we don't need to change the namespace manually as it will be back automatically once we return the method.
and we don't need try-catch (at least for this purpose) too.
[Background]
InterSystems IRIS family has a nice utility ^SystemPerformance (as known as ^pButtons in Caché and Ensemble) which outputs the database performance information into a readable HTML file. When you run ^SystemPerformance on IRIS for Windows, a HTML file is created where both our own performance log mgstat and Windows performance log are included.
Hello all,
If we have a global structured something like this:-
- ^test(1)="Dave^Engineer"
- ^test(2)="Bethan^Manager"
- ^test(2,"transferred")="2024-01-04"
- ^test(3)="James^Administrator"
- ^test(4)="Sophia^Marketing Executive"
- ^test(4,"transferred")="2023-11-20"
It is fairly straightforward to map, and from a reading perspective everything works fine, but when inserting/saving the "transferred" node is created even if the 'transferred' field is not set. Is there a way to populate the node only if the field mapped to it is set?
Thanks
Colin
Can someone please tell me like how we can retrieve SuperSessionID in classMethod ??
(for SessionID i now the syntax [Set SessionID = ""_$get($$$JobSessionId)] but for SuperSessionID i don't know.)
Now i want to use SuperSessionID instead of SessionID, outside the package.
Also one confirmation that "SessionID keeps same in entire message flow or it varies ?? i heard that SessionID may change in diff instances."
please explain me which ID keep unique (SessionID or SuperSessionID) ??
I want to filter the message base upon that only...
As a InterSystems HealthShare Developer, you will be a part of an Agile team to build healthcare applications and implement new features while adhering to the best coding development standards.
The first developer preview of InterSystems IRIS 2024.2 and InterSystems IRIS for Health 2024.2 has been posted to the WRC developer preview site. Containers are not available for this preview, but we’ll be sure to post them next time.
This is the earliest in the release cycle that we’ve ever posted a developer preview and there aren’t any “highlight” worthy features that are complete. I’ll list them as they get closer to done in future preview releases.
Initial documentation can be found at these links below.
InterSystems FAQ rubric
If the journal file is too large to be searched or filtered using the Management Portal, you can refer to it using the following two methods.
① How to use the ^JRNDUMP utility
② How to reference it in a program
================================================== ==========
① Using the ^JRNDUMP utility. For example, if you want to select all records in the journal file that include the global reference ^ABC, do the following:
*Please execute all commands below in the %SYS namespace.
DO SELECT^JRNDUMP("C:\MyCache\mgr\journal\YYYYMMDD.
This article will describe processes for running unit tests via the InterSystems Package Manager (aka IPM - see https://openexchange.intersystems.com/package/InterSystems-Package-Manager-1), including test coverage measurement (via https://openexchange.intersystems.com/package/Test-Coverage-Tool).
Unit testing in ObjectScript
There's already great documentation about writing unit tests in ObjectScript, so I won't repeat any of that. You can find the Unit Test tutorial here: https://docs.intersystems.com/irislatest/csp/docbook/Doc.View.cls?
Hi,
I am using embeded python to utilize some pythonic library but i got a problem on my hand.
One of the python function i am using return multiple values
in python you would do something like that :
val1, val2, val3, = function(params)
In COS I got something like that :
lib = ##class(%SYS.Python).Import("lib")
val1 = lib.function(params)And I don't know how to get the second and third values.
Is there a way to get them?
Hello,
I have a variables X="1,4,6,8,9,12" and I want to write a For loop with this variable in similar with the loop below:
For Y=1,4,6,8,9,12 {
Write Y,!
}
Can someone help? Thank you.
If you have system tables implementing the "VERSIONPROPERTY" functionality, you may encounter error 5800. This article explains how this error occurs and provides solutions to resolve the issue.
When version checking is implemented, the property specified by VERSIONPROPERTY is automatically incremented each time an instance of the class is updated (either by objects or SQL).
For example:
ClassMethod RunVersionChange() As %Status
{
Set sample = ##class(dado.TblSample).%OpenId("42")
Write !,"VERSIONPROPERTY value: "_ sample.VersionCheck
Do sample.Developing with InterSystems Objects and SQL – IN PERSON (Cambridge office) April 29-May 3, 2024 9:00am-5:00pm US-Eastern Time (EDT)
- This 5-day course teaches programmers how to use the tools and techniques within the InterSystems development environment to build high-performance transactional applications. Learners build a complex application using an IDE, object-oriented design, SQL and unit testing.
- This course is applicable for users of InterSystems IRIS Data Platform and Caché.
