Hey Developers,
We know you've been waiting for this for a whole year. The time has finally come!
Join the Advent of Code 2022 with InterSystems and participate in our ObjectScript contest to win $$$$ prizes!

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.
Hey Developers,
We know you've been waiting for this for a whole year. The time has finally come!
Join the Advent of Code 2022 with InterSystems and participate in our ObjectScript contest to win $$$$ prizes!

While you don't need to take your exam before the end of 2022, the vouchers provided to the UK&I Summit 2022 must be redeemed before January 1, 2023. Please register for an exam before time runs out.
You can find additional information about the InterSystems Certification Program here.
In simple terms, Web scraping, web harvesting, or web data extraction is an automated process of collecting large data(unstructured) from websites. The user can extract all the data on particular sites or the specific data as per the requirement. The data collected can be stored in a structured format for further analysis.

It’s that simple !!
Was wondering if anyone had a simple way of calling ##class(Ens.Director).EnableConfigItem() within a Business Process or adding code to a Custom Service to start or stop the object?
The use case is that I have a Process that uploads a file into a external SQL table. When it is finished I want it to kick off another Service that does the processing of the data that it just uploaded. Once it is finished the response is sent back to the service and when the service receives the response from the process, I want to stop that service from running.
so...
Hi Community,
Watch this video to get an introduction to data types in InterSystems ObjectScript, and see how to use three common data types: strings, lists, and objects:
Hi Community,
Enjoy watching the new video on InterSystems Developers YouTube:
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.
set a = ##claHi Developers,
Enjoy watching the new video on InterSystems Developers YouTube:
When creating a PRA (Privileged Routine Application; which by the way is not relevant just for Routines but also for Classes/Methods), it is important to make sure you include a new $ROLES, before calling AddRoles(). For example:
new$ROLESset status=$System.Security.AddRoles("MyPrivilegedRoutineApplication")This way you ensure that indeed the added (elevated) roles "evaporate" for the User running this code, once the User is out of the scope of that routine/method.
[Thank you @Andreas Dieckow for validating this]
TL;DR: This article describes an introductory-level project that exercises some string-manipulation functions in both ObjectScript and Python…with specs from a song.
After you’ve written your first “Hello World!” program, are you ready for a new fun challenge? An old, very popular (at the time) song may be just what you need.
While I was driving around on vacation in southern Maine, the local “Legends” radio station played the old classic, “The Name Game” by Shirley Ellis (https://www.youtube.com/watch?v=5MJLi5_dyn0).
Hi, how do I create a trigger that will only set the value of the "Status" field for new objects, not for all available?
Class CarDealer.Order Extends (%Persistent, %Populate)
{
Property Title As %String
Property Status As %String(VALUELIST = ",InProgress,Done,Canceled");
Trigger setStatus [ Event = INSERT, Foreach = row/object, Time = AFTER ]
{
&sql(update CarDealer.Order set Status = 'InProgress')
}
Hi Developers!
Often when we develop some library, tool, package, whatever on InterSystems ObjectScript we have a question, how we deploy this package on the target machine?
Also, we often expect that some other libraries already installed, so our package depends on them, and often on some particular version of it.
When you code on javascript, python, etc the role of packages deployment with dependency management takes package manager.
So, I'm pleased to announce that InterSystems ObjectScript Package Manager available!
Hi Community,
I need to convert HL7 Message into FHIR Format.Can anyone share basic reference for FHIR ADT^A01 message?
For converting HL7 message to FHIR we need to convert HL7 to SDA3 format and then converting SDA3 to FHIR format.
Please Share few basics steps for converting SDA3 to FHIR message?
Thanks
Smythee

preface
Since the contact with IRIS, it has been used most in hospitals as an ESB integration engine, as a link in the hospital's integration platform+data center. However, you can also develop some restful pis to be used as the backend of front end and back end separation projects
List of articles
Introduction
List of articles
I. Development of technologies and tools
II. Development Path and Relevant Codes
1. database
2. Preparatory work
3. Steps associated with developing an interface
4. Presentation of achievements
Summary
This article will show the CRUD operations related to IRIS in a simple page:

Ye
Hi,
I
want to get the values from a serial property because my code depends upon the class serial class.
For example
Serial class
Class Data.Serial Extends %SerialObject
{
Property FirstName as %String;
Property LastName as %String;
}
Persistent class
Class Data.Persistent Extends %Persistent
{
Property MPID as %Integer;
Property Name as Name.Serial;
}
Now i need save MPID and Name(Serial class property into SQL Table ) so i am trying the below class
Class Data.TestUtil Extends %RegisteredObject
{
Method Savedata(MPID,FirstName,LastName)
{
Set tSC=0
Set Obj=##Class(Data.Persistent).%New()
Set Obj.MPID=MPID
Set
Hi,
when I using ObjectScript Trigger Code , I want to get whether the fields has changed by using "{fieldName*C}" , actually, fieldName in "{fieldName*C}" is a real field name ,but in my code, fieldName is a variable as follows:
SET stat=##class(%SYSTEM.SQL).GetColumns(tableName,.byname,.bynum,1)
IF stat=1{
SET i=1WHILE$d(bynum(i)){
SET xColName=bynum(i)
SET valComp={xColName*C}
IF valComp=1{
SET oldVal=1//{xColName*O}SET newVal=2//{xColName*N}
&sql(INSERTINTO Yan.LogTableExt(Parref,ProperName,OldValue,NewValue) VALUESHi, devs!
In ObjectScript I can refer to a class parameter as:
write ..#ParameterName
How do I do the same in Embedded Python?
Hi
I have a Zen Page with tablepane which has a datasource in a different namespace to that of the Zen Page. When the page is run, no data is returned and the tablepane is not populate, even though the rerferenced table contains dat.
The tablePane code is as follows:
<tablePaneid="DataExtractionCurrent"showZebra="true"cellSpacing="2px"OnCreateResultSet="DataExtractionCurrent"></tablePane>The OnCreateResultSet points to the following method:
Method DataExtractionCurrent(Output tSC As%Status, pInfo As%ZEN.Auxiliary.QueryInfo) As%ResultSet [ ZenMethod ]
{
new$namespaceseWe need to resize existing images already in %GlobalBinaryStream to create thumbnails.
The requirement is also to use the method to resize new images that are uploaded.
Does anyone have a solution for this ?
Is there a way to add specific table permissions to a security role programmatically? I'm working on scripting some of the initial setup work when we sell certain add-ons to our software, and I see how I can assign resources to a role and give it a description, but I don't see how I tell it that this role gives the user, for example, SELECT privileges only on the invoices table, or SELECT, INSERT, UPDATE, and DELETE.
Hi Community ,
Can anyone please explain how to use EnsLib.EMail.AlertOperation operation to send notification to my email id when any error occurs in my production?
Please give any example how to use EnsLib.EMail.AlertOperation operation class
Thanks,
Smythee
The topic of for/while loop performance in Caché ObjectScript came up in discussion recently, and I'd like to share some thoughts/best practices with the rest of the community. While this is a basic topic in itself, it's easy to overlook the performance implications of otherwise-reasonable approaches. In short, loops iterating over $ListBuild lists with $ListNext or over a local array with $Order are the fastest options.
As a motivating example, we will consider looping over the pieces of a comma-delimited string.
A natural way to write such a loop, in minimal code, is:
ForHello
I have a class to render reports as pdf. My problem that arabic characters in report replaced with ####.
Please find my code below
#dim stream as %Stream.Objectset report = $classmethod($piece(reportClass, ".cls"), "%New")
set report.RUID = RUIDset %response.ContentType = "application/pdf"
set sc = report.GenerateReportToStream(.stream, 2) return:$$$ISERR(sc) sc
do stream.OutputToDevice()
return $$$OK
Your help is appreciated.
Hello all; I am using a one-to-many relationship. I have a Claim (one), in a relationship with Lines (many), but the Claim is storing a list of Lines IDs, rather than the Lines storing the Claim Id. This seems upside down, and not what I expected.
Class Claim
{
Relationship ClaimLineRel as ClaimLine [Cardinality = many, Inverse = Claim];
}
Class ClaimLine
{
Relationship Claim as Claim [ Cardinality = one, Inverse = ClaimLineRel, OnDelete = cascade];
Index ClaimIndex on Claim;
}But the storage globals for Claim show data in the ClaimLine spot:
^ClaimD(1)=$lb("",$lb(2,3).
Good morning, evening, night,... ![]()
A small reflection/question for today... it's true that new IRIS for Health (I4H) releases are more and more powerful each time regarding FHIR capabilities. Nowadays it allows us to consume FHIR resources with extrem easiness, we can connect with end-points in external FHIR servers very easily and make I4H act as passthrough or consume their resources... or, even more, we can define, configure and run a FHIR repository in, literally, less than 5 minutes.
Hi all.
I have a scenario where I am receiving NACKs and I'd like to adjust the error handing of the operation based on the content of the NACK.
For example, I could receive the following and want to move onto the next message:
MSH| ^~\&|||||20221025083135.489+0100||ACK ^A02^ACK|9271|D|2.5.1 MSA|AE|1664378390234 ERR|||207 ^Application internal error ^HL70357^^^^^^Cannot transfer patient, encounter is cancelled.|E
However, I could also receive the following and want to keep retrying:
MSH| ^~\&|||||20221014103828.043+0100||ACK^A03^ACK|1049|D|2.5.1 MSA|AE|1665740278804 ERR|||207^Application
Hi ,
Still a newbie for ensemble, I am trying to convert XML message to HL7 Message. I am using Custom schema for XML structure which includes MSH and PID segments from HL7 Message.
These are the service, process, Operation classes i am using
Business service-EnsLib.EDI.XML.Service.FileService
Business Process-EnsLib.MsgRouter.RoutingEngine
Business operation -EnsLib.HL7.Operation.FileOperation
I am using data transformation to convert XML message to HL7 message and data transformation is working fine and im getting this in the business operation.
|
ERROR <Ens>ErrGeneral: Not routing |
Good men don’t need rules.
The Doctor.
It's not an easy task to be a master of dates and times, it is always a problem and sometimes confusing in any programming language, we are going to clarify and put a few tips to make this task as simple as possible.
Get on the TARDIS and I'm going to turn you into a Time lord

Hello,
I am trying to grab a specific zip file from a webpage but once I grab the zip file I need to grab a specific file within that zip file and I was hoping someone could explain how to do this or provide an example
With $Property is possible to dynamically get and set values on property of an instanced class and with $ClassMethod is possible to invoke methods from a class.
I would like to know: Is there an elegant way to do Write and Set dynamically on variables without using Xecute?