Question
· Apr 14, 2021

Perl / Python Bindings from Cache 2018 to IRIS for Health 2020

Hello,

I believe that the Perl and Python bindings that exist on Cache / Ensemble do not exist on IRIS for Health 2020.1 ... is that correct?

 

Is there any similar documentation and samples (like below) , that show an example of how to run a basic Perl or Python script that connects with ODBC or whatever the recommended way?

 

http://docs.intersystems.com/cache20102/csp/docbook/DocBook.UI.Page.cls?...

http://docs.intersystems.com/cache20102/csp/docbook/DocBook.UI.Page.cls?...

 

 

Thanks

Product version: IRIS 2020.1
Discussion (6)0
Log in or sign up to continue

If you get back large results sets that you use for further processing PyODBC will be better suited.
But for a small number of values, the overhead at both ends to service ODBC structures may not pay off
since both ends have to get their internal structure in to  ODBC and out of it.
I don't have measured the difference so this is just a guess:
- for the typical embedded SQL returning < 1..10 rows a MethodCall might be more efficient.
This doesn't prevent you from using and tuning an SQL SELECT isolated in IRIS environment. 
In any case, the transfer between PY and IRIS is the slowest piece.
The less data you transport the faster the action is completed.
And transport in blocks wins over isolated pieces in loops.

This documentation shows how to connect and interact with IRIS using Python.  Following this worked for me:

https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cls...

Using port 1972 per the example worked in my case but your installation may vary.  It requires Python 3 (3.4+).  When you download the Intersystems wheel file, make sure that the filename remains unchanged otherwise pip won't be able to install it.

Marlin