Article
· Jan 14, 2022 3m read

Plug and play DATASETS with ObjectScript Package Manager (ZPM)

With the release of InterSystems IRIS 2021.2 Preview and all-new LOAD DATA functionality dataset can by added with Objectscript Package Manager (ZPM) 

Medical Datasets contains following 12 datasets. For dataset tables and data details please visit ONLINE DEMO by using SuperUser | SYS 


In order to use any of the above listed dataset we can add in our namespace by using dataset ID, So Let's add Synthetic medical dataset 

First of all we need to install dataset-medical package which can be done by using below command:

zpm "install dataset-medical

Now we are ready to import dataset. Dataset can be added or removed either by Terminal or by Web Application 


ADDING DATASET FROM TERMINAL

We can add dataset by calling ImportDS function of dc.data.medical.utility class by passing dataset ID from terminal:

do ##class(dc.data.medical.utility).ImportDS(1)

That's it, Our first dataset is created. 

 

Dataset "synthetic" is created with 11 Tables and 83,341 records, which can be confirm by Management Portal

Removing Dataset

Use below command to remove particular dataset by passing it's ID 

do ##class(dc.data.medical.utility).RemoveDS(1)

Adding ALL datasets

To install all the datasets pass 999 to ImportDS function

do ##class(dc.data.medical.utility).ImportDS(999)

Removing ALL datasets

 And to remove all the datasets pass 999 to RemoveDS function

do ##class(dc.data.medical.utility).RemoveDS(999)


ADDING DATASET FROM TERMINAL

Navigate to http://localhost:52773/csp/datasets/index.csp and press Install DataSet button image image

 

View Data from Web Application

Navigate to http://localhost:52773/csp/datasets/index.csp and click any table from sidebarimage

Removing DataSet from Web Application

Navigate to http://localhost:52773/csp/datasets/index.csp and press Remove DataSet button

image

Dataset is removed successfully

image

 

Thanks

Discussion (0)1
Log in or sign up to continue