User bio

15+ experience with InterSystems products, in different sizes of projects, different countries, and different fields except for healthcare.

Melbourne, VIC, Australia
Member since Dec 4, 2015
Pinned posts:

I think you just confusing $listbuild with list in BPL context. In BPL when you define it as List Collection, it will use class %Collection.ListOfDT, or in case of array it will be %Collection.ArrayOfDT

That means, that you should use 

 if 'context.Facilities.Find(##class(Ens.Rule.FunctionSet).SubString(context.EpicDepartmentID,1,4))
 {
   do context.Facilities.Insert(##class(Ens.Rule.FunctionSet).SubString(context.EpicDepartmentID,1,4))
 }

The support for NodeJS in IRIS is quite primitive and limited to only native functions, globals, methods, no SQL

check in IRIS folder, what do you have installed with IRIS for nodejs

I don't have windows, only docker, and in my case

/usr/irissys/bin/iris1200.node
/usr/irissys/bin/iris800.node
/usr/irissys/bin/iris1600.node
/usr/irissys/bin/iris1400.node
/usr/irissys/bin/iris1000.node
/usr/irissys/dev/nodejs/intersystems-iris-native/bin/lnxubuntuarm64/irisnative.node

If you want to use IRIS SQL from nodejs, you can try my package, which you can install with npm

npm install intersystems-iris
const { IRIS } = require("intersystems-iris");

async function main() {
    const db = new IRIS('localhost', 1972, 'USER', '_SYSTEM', 'SYS')
    console.log('connected')
    let res = await db.sql("select 1 one, 2 two")
    console.log(res.rows);
    await db.close()
}

main()

It's quite simple at the moment, only supports SQL with no parameters, but should work I believe

Open Exchange applications:
Certifications & Credly badges:
Global Masters badges:
Followers:
Following:
Dmitry has not followed anybody yet.