%%iris magic for IPython, can run ObjectScript command in Notebooks.
It can be run in any Notebook and does not require any special setup on IRIS or the Notebook.
As you can see, the first line load the magic, the second line connect to the server, the third line run the ObjectScript command.
All of this demo is in the example/Notebooks/Demo-Iris-Magic.ipynb
To run the demo run the following command in the root of the project:
Then go to this url: http://127.0.0.1:8888/notebooks/Demo-Iris-Magic.ipynb
%%iris Set x = 1 Write x
You can also use the magic to run SQL query.
/!\ You need to install the sql extension first.
The sql extension is not part of the standard IPython installation. You can install it with the following command:
pip install ipython-sql
%sql SELECT 1
In order to use this magic, you need to install the ipython-iris-magic package.
pip install ipython-iris-magic
All the dependencies will be installed automatically.
%%iris iris://superuser:SYS@localhost:1972/USER set test = "toto" zw test