Sure you can, for example to retrieve all the patient with an observation based on the code : 8302-2

[FHIR EndPoint]/Patient?_has:Observation:patient:code=8302-2

More info here : https://www.hl7.org/fhir/search.html#has

For the python part have a look at this git :

https://github.com/LucasEnard/fhir-client-python

It's a simple example how to use python client to interact with a FHIR server.

For fhir-py to create the same query use raw search :

https://github.com/grongierisc/fhir-py#raw-parameters

Last but not least, check out our neat implementation of SQL On FHIR aka FHIR SQL Builder

Demo here : https://github.com/grongierisc/iris-fhirsqlbuilder

How to setup a secure connection :

  1. Generate a key pair :
openssl req -x509 -nodes -days 1 -newkey rsa:2048 -subj /CN=* -keyout /irisdev/app/server.key -out /irisdev/app/server.crt
  1. Configure IRIS super server with SSL/TLS :

https://docs.intersystems.com/iris20223/csp/docbook/Doc.View.cls?KEY=GTL...

  1. Use certificate to connect :
python3 -m irissqlcli iris://SuperUser:SYS@localhost:33782/USER -c server.crt

If I understand correctly, the trick is to load the "src/gbl/SYS.xml" file that holds the configuration of git-source-control module.

If we create a new file like a BP or a DTL, we still have to add it to the source control module with the UI.
Then, if we do so, we have to update the "src/gbl/SYS.xml" file with the new file.

Am I right ?

I'm not tottaly agree with you.

Imagine you are new to iris, you just wish to play with our SQL engine.

With your proposal, you have to know how to connect to a terminal and know the magic command (zzq, BTW i was not aware of this one) to run a query.

Then, you can't do that remotely or with out SSH.

To finish, with your example, you don't show us how to do it from a Shell.

In my point of view, this app is a game changer.

Let me explain why.

Imagine you have an DDL statement that you want to execute on a database.
Example:

File: misc/init.sql

CREATE TABLE test.formation (
    name varchar(50) NULL,
    room varchar(50) NULL
);

INSERT INTO test.formation
(name, room)
VALUES('formation1', 'salle1');

You can execute this statement in the irissqlcli app by using the following command:

irissqlcli iris://_SYSTEM@localhost:51776/USER -W < misc/init.sql

Before this app, you had to use the terminal to execute this command.

cat <<EOF | iris session iris

do \$SYSTEM.SQL.Schema.ImportDDL("/irisdev/app/misc/init.sql",.log)
if log'="" { write "Error: ",log }
h
EOF

Let's compare the two commands:

tool command comment
irissqlcli irissqlcli iris://_SYSTEM@localhost:51776/USER -W < misc/init.sql One line, easy to read, eeasy to maintaine
terminal cat <<EOF \| iris session iris <br> do \$SYSTEM.SQL.Schema.ImportDDL("/irisdev/app/misc/init.sql",.log) <br>if log'="" { write "Error: ",log } <br>h <br>EOF multiple line, arkward to read, hard to maintain, must understand the syntax of the terminal, had to be on the same machine

One last thing, if I want to extract the data from a table, I can use the following command:

irissqlcli iris://_SYSTEM@localhost:51776/USER -W -e "SELECT * FROM test.formation" --csv

This command will return the following result:

"name","room"
"formation1","salle1"

Try to do the same thing with the terminal ;).

cat <<EOF | iris session iris
do ##class(%SQL.Statement).%ExecDirect(,"SELECT * FROM test.formation").%DisplayFormatted("CSV",,,.filesUsed)
do ##class(%Stream.FileCharacter).%OpenId(filesUsed(1)).OutputToDevice()
h
EOF

Hi dear community,

If you lack inspiration for the contest, here are some ideas:

  • A tool to improve the load of DDL or SQL statements in IRIS.

    • Why, because for now, we have to run an iris terminal then run an objectscritp command to load the DDL or SQL statements.
    • I wish a way that we can have a tool that bring the ability to parse a DDL or SQL file from a shell.
      • Example : iris load -f /path/to/file.sql
  • A tool to automatically export objectscript classes to the local folder

    • I know we can do it with Timothy's tool, but I wish a simple hook that just export new classes or modified classes to the local folder. Not the whole source control system.
Class codeGolf.Pyramid
{

ClassMethod BuildPython(f As %Integer) [ Language = python ]
{
for i in range(f):
    print(' ' * (f - i - 1) + '#' * (2 * i + 1))
}

/// Description: Build a pyramid of height f
ClassMethod Build(f As %Integer) As %Status
{
    Set sc = $$$OK
    For i = 1:1:f {
        set space = $tr($j("",f-i)," "," ")
        set hash = $tr($j("",2*i-1)," ","#")
        Write space_hash, !
    }
    Return sc
}

}

Hi Joe,

The 2 dots syntax is used to access the properties and methods of the current object.
You can also use $this to access the current object.

For example, if you have a class called "MyClass" and you have a property called "MyProperty" in that class, you can access the property value by using the following syntax:

User.MyClass Extends EnsLib.BusinessService
{
    Property MyProperty;

    Method MyMethod()
    {
        set ..MyProperty = 10;
        set $this.MyProperty = 10;
    }
}

In your case, you can use the following syntax to access the methods of the EnsLib.File.InboundAdapter class:

User.MyClass Extends EnsLib.BusinessService
{
    Parameter ADAPTER = "EnsLib.File.InboundAdapter";
    Property Adapter = "EnsLib.File.InboundAdapter";

    Method MyMethod()
    {
        do ..Adapter.AdapterMethod()
        do $this.Adapter.AdapterMethod()
    }
}

Hope this helps.