FIrst of all thank you for your time in reading this question and writing a response,

We would need some help,

-> Our objective is to control which method is being used in the service: GET POST PUT

We have tried to understand the example REST Service: Demo.REST.DirectoryService


After that we have tried to create our own custom rest service,

please take a few minutes to examine the following code:


0 1 34

Good day, developers!

The "apptools-admin" project is not only a set of tools for the administrator, but a platform for the rapid creation of a prototype of any solution.
For example, Photo Album, Music Player, and Personal Library all come together in a user-friendly treasure chest design.

Load http:// your-host:your-port/apptoolsrest/a/infochest

Change the path to your treasure files and start viewing, listening or reading from any convenient device: desktop, tablet or smartphone.

0 0 32

Recently I wanted to get a list of all cached queries and their texts. Here's how to do that.

First create an SQL Procedure returning Cache Query text from a Cached Query routine name:

Class test.CQ

/// SELECT test.CQ_GetText()
ClassMethod GetText(routine As %String) As %String [ CodeMode = expression, SqlProc ]


And after that you can execute this query:

0 1 20


First of all thanks for your time to read and reply,

We would need some help,

We have an ORM_O01 which has a NTE.3 with a Line Feed

Our Process converts the XML to ER7 using the ITB as follows:

set context.mensajeHL7 = ##class(ITB.HL7.Util.Convert).XMLToER7(hl7,.tSC,"2.5")

When we show the ER7 we observe:

INTE|1||Psa libre\X0A\ Indice psa

We have thought about the following solution, where mensajeXML is the XML representation of the ER7 shown:

0 0 14
Robert Cemper · Feb 16, 2021 2m read
FOREACH for ObjectScript

As you know ObjectScript has no FOREACH system command nor system function.
But it has a wide room for creativity.

The task is to loop over a global or local array and do something FOR EACH element.

There are 2 possible solutions:
- creating a macro that generates the required code sequences
- creating an Extended Command to perform the action.

0 3 145

Hello everyone,

I have an issue with using "Open" function.

My goal is to execute a shell script with parameters like as:

/trak/FRXX/config/shells/ "login|password|NOMUSUEL|PRENOM|NOMDENAISSANCE|1234567891320|199999999999999999999999|09%2099%2099%2099%2099|31%2F12%2F1999|242%20IMPASSE%20DES%20MACHINCHOOOOOOOOSE%20||99999|SAINT%20BIDULETRUC%20DE%20MACHINCHOSE|isc%24jhu|123456|123456798"" 2>&1"

But when some parameters are too long, I have a <NAMEADD> error.

0 4 101
Robert Cemper · Feb 8, 2021 3m read
WebSocket Client with embedded Python

This is a demo to make use of a simple WebSocket Client with Embedded Python in IRIS.

To continue my series of WebSocket Client I have added an example written in Python.
The most impressive experience was how easy the writing and testing of the client was
which happened total offline from IRIS.
Embedding, running and feeding the client with data from IRIS was also incredibly simple.

0 3 64


We would need some help,

Our aim is to send an image as binary data using a REST Service

Currently we do the following:

1 We get from the external system a binary image in our REST Operation

2 We encode it to Base64

set linea=""
    while (tResponse.Data.AtEnd = 0) {
        set linea = linea_$system.Encryption.Base64Encode(tResponse.Data.Read(57))

3 We send it to the Process in a Response Message:

0 4 72


We would need some help, please;

We would like to handle when we have a date with hours:


And when we have it without the hours part, as follows:



For the first case we used:


For the second one we wrote:



0 1 38
Scott Roth · Jan 13, 2021
Handling Errors

I have a case where our EMR is sending data, but not all the values needed for the Ancillary are valued properly and causes that message to error/halt processing on the Ancillary system, not ideal but its what they do. I would expect them to still process the message except that 1 field, but they don't.

I want to add validation to make sure certain fields are valued correctly for the Vendor. 

So I add some statements to take those items that don't pass this validation out to a batch file with headers.

0 9 125
Eduard Lebedyuk · Jan 10, 2021
Code Golf: Diamonds
To start the year let's have a round of CodeGolf!

You know the drill. Shortest solution wins.

Print a size ascending range of Diamonds using the numbers 1 to 9, ranging from size 1 to size N, each diamond separated by a blank line.

A size 1 diamond should look like this, a single centered 1:


With the size N=9 diamond looking like this:

0 19 210

I am currently evaluating Source Control systems that we can use for both MS SQL, MS Visual Studio, and InterSystems IRIS. For both MS SQL and MS Visual Studio we do have the option of either Azure or GitHub.  I understand when we upgrade to IRIS 2019.1 we have options for Source Control, and in previous Global Summit's I have heard GitHub discussed.  So why can't I user GitHub for both MS SQL/MS Visual Studio and IRIS?

A couple of questions come to mind starting to think about Source Control

1 7 540


I am trying to use %ZEN.proxyObject to send out in JSON format so I do:

    set tProxyRequest = ##class(%ZEN.proxyObject).%New()
    set tProxyRequest.notanumber = "28001"
    set tProxyRequest.aboolean = "true"
    set tBody = ##class(%GlobalCharacterStream).%New()
    do ##class(Ens.Util.JSON).ObjectToJSONStream(tProxyRequest,.tBody,"aelotwu")
    w tBody.Read()

and I get:

0 10 1,002


I seem to be able to execute sqlproc using the convention defined here provided the package/folder is a single level. As, soon I have a nested folder structure I get an error while trying to execute this. 

For instance, 

select id, Utils.Users_getRole(id) roles from users.users

works fine while, 

0 3 62

I have multiple files with different columns, first 9 values are fixed, so i want to ignore the first value, and next 8 values i want to combine into one value using ^ sign

Current Format


Desired Format


Reading each line from the file use below code.

0 11 152



I would like to create a new message of a particular type and append various segments programmatically.  I have started with the following snippet.  What I am currently finding difficult is to define a segment of a particular segment structure.  I would like to append a pid segment of 2.3.1 to my message.  I know I could you the importfromstring but I wanted to know whether there was a better way of achieving this.


0 2 120

i want to restrict certain IPs (ip for now and looking for more such parameters) from running my URL for security purposes...

i wanted to know how to access their ips and compare them with the list of restricted IPs, also if not IPs are there any other unique browser parameters which can be used for access control? and enhance security

0 2 93

Date range queries going too slow for you?  SQL Performance got you down?  I have one weird trick that might just help you out! (SQL Developers hate this!)*

If you have a class that records timestamps when the data is added, then that data will be in sequence with your IDKEY values - that is, TimeStamp< TimeStampif and only if ID1 < IDfor all IDs and TimeStamp values in table - then you can use this knowledge to increase performance for queries against TimeStamp ranges.  Consider the following table:

1 8 16,480
Ewan Whyte · Aug 3, 2020

Hi, I want to INSERT a customerID and customerName to a table if the customerID does not exist. Or UPDATE if they've changed their name.
I've reviewed the documentation ( and have confused myself with the INSERT OR UPDATE statement. Rather than using two individual statements , is there a way to get it in one?

What I have at the moment doesn't do anything. In fact it errors.

0 3 162


We would like to learn how would you approach this task.

We would need to check every day a set of folders which are outside our server (in fact we could see them as if they were "inside" the server), then we need to check for modified or created files in the last day, and move all the ones which match the criteria to just one folder in our server.


We have thought about doing the following:

1) Create a task to run it each day:

0 5 180



We would need to iterate all over the OBXs list and get their OBX3 CE1 to determine if it is the lab result we need to send to the output system.


We wonder how could we achieve this in a foreach component inside a Bussiness Process.


We think we would need to use a foreach because of it is needed to generate a message, for each one of the OBX which have the OBX3 CE1 that the output systems uses for the lab results.


0 1 169