#JavaScript

0 Followers · 129 Posts

JavaScript, often abbreviated as JS, is a high-level, interpreted programming language. It is a language which is also characterized as dynamic, weakly typed, prototype-based and multi-paradigm.

Learn more.

Article Rob Tweed · Feb 26 6m read

Introduction

My guess is that most IRIS developers create their applications using its native ObjectScript language or, if using an external language, then most likely using either Java, Python or perhaps C++.

I suspect that only a minority have considered using JavaScript as their language of choice, which, if true, is a great shame, because, In my opinion and experience, JavaScript is the closest equivalent to ObjectScript in terms of its ability to integrate with the IRIS's underlying multi-dimensional database. 

0
0 0
Question David Saunders · Sep 4

Given the code below, I need help with getting the collected column widths from the Demo.Configuration table and stored in the columnWidths zne page property. As I understand it, I should be able to retrieve it using zenPage.columnWidths in the setColumnWidths or dgRender clientMethods but the alert is showing that it cannot be retrieved as it shows a value of Null. Once I can retrieve those values, then I want to set the widths of the colmns of the dynaGrid according to the values in the ^Demo.Configuration table. The data pulled in from the CSV file that creates ^Demo.Import can have a

0
0 0
Question David Saunders · Aug 12

I am trying to use upload.csp as a template for choosing a CDV file to process. I am calling it from a zen page using this:
<button caption="Import Client Consultation Extract" 
       controlStyle="width:500px; height:100px; font-size:1.5em;"
         onclick="zenPage.importExtract();"/>

ClientMethod importExtract() [ Language = javascript ]
{
    // Open CSP popup to upload the CSV
    //alert('importExtract called.');
    zenPage.launchPopupWindow(zenLink('Upload.CSP'),'Upload Client Consultation extract',
                              'status,scrollbars,resizable,width=750,height=250');
}

0
0 0
Question Aaron Laferty · Aug 14

Hi all,

I’m running into an issue with a %ZEN.Component.tablePane in a Zen page.

We have:

  • A fully styled table with all columns defined
  • A backend query (SearchMessages) that accepts multiple filter parameters
  • A set of input fields at the top of the page for filtering (text, date, and checkboxes)

We’re trying to run the query from a button click using a client-side method (runSearch()) that collects the filter values, sets them as parameters, and calls executeQuery().

0
0 0
Article Dmitry Maslennikov · Jul 28 5m read

Overview

The typeorm-iris project provides experimental support for integrating TypeORM with InterSystems IRIS, enabling developers to interact with IRIS using TypeORM’s well-known decorators and repository abstractions. This allows a more familiar development experience for JavaScript and TypeScript developers building Node.js applications with IRIS as the backend database.

While the project implements key integration points with TypeORM and supports basic entity operations, it’s not yet battle-tested or suitable for production environments.

0
0 0
Article Harshitha · Aug 3 2m read

Working in healthcare IT as a young developer, especially on InterSystems TrakCare, you quickly realize one thing: it’s not just about HL7 messages or backend integrations. A hugepart of making TrakCare work smoothly for hospitals comes down to how it’s configured, customized, and supported on the application side.

That’s where people like me come in—techno-functional developers who understand both the tech and how it impacts actual hospital workflows.

We’re Not Just Techies (or Functional Consultants)

Our role sits right in the middle. We're the ones:

0
0 0
Question Ronaldo Nascimento · Jul 22

Working on wrapping an IRIS Cache ObjectScript method that runs for a few seconds. Trying to get UI updates to show BEFORE the method runs in an async/await function. But it seems to be running synchronously rather than asynchronously . So my question is does IRIS/ObjectScript CSP pages support futures with JavaScript or does it run all synchronously.

0
0 0
Question Ward De Backer · Oct 26, 2022

Hi,

If I test the Native api for Node.js from the documentation, I noticed (if I'm correct) all methods and calls are synchronous. By default due to the nature of Node.js, there is only one thread of execution and normally  all JavaScript methods and all calls should be asynchronous and use either a callback function (the "old way") or promises or the async/await contruct to return their result, e.g.:

  • myFunction(params, callbackFunction(response))
  • myFunction(params).then(resolveFunction(response))
  • async someFunction() {
    ​​​​​  response = await myFunction(params)
    }
13
0 716
Question Harshitha · Jul 1

Hi everyone,

I'm working with JavaScript in InterSystems IRIS, specifically in CSP pages. One issue I'm running into during development is that the browser keeps loading the cached version of my JavaScript files, even after I’ve made changes or recompiled the code.
I would have to clear my cache files or browser history for it to reload and work.

0
0 0
Article Alex Alcivar · Jul 28, 2024 6m read

For a long time I have wanted to learn the Django framework, but another more pressing project has always taken priority. Like many developers, I use python when it comes to machine learning, but when I first learned web programming PHP was still enjoying primacy, and so when it was time for me to pick up a new complicated framework for creating web applications to publish my machine learning work, I still turned to PHP. For a while I have been using a framework called Laravel to build my websites, and this PHP framework introduced me to the modern Model-View-Controller pattern of web

0
0 0
Question Michael Davidovich · Apr 10

Hello,

Our software commonly returns a full result set to the client and we use the DataTables plugin to display table data.  This has worked well, but at datasets grow larger, we are trying to move some of these requests server-side so the server handles the bulk of the work rather than the client.  This has had me scratching my head in so many ways.  

I'm hoping I can get a mix of general best practice advice but also maybe some IRIS specific ideas.

Some background

0
0 0
Question John McBride · Mar 4

Hello, Does the NodeJs package work when running a node js file on windows (nodejs for windows)? I've added the package by running npm install <package location folder>

I have the following index.js file, but when running from node (windows) I get the following error. Does the NodeJs package build the output files when the package is added or does it just assume linux as the underlying os?

Error: Cannot find module './bin/winx64/irisnative.node'

0
0 0
Question Dan Murt · Jan 3

Hi Community,

I have a CSP page I am developing with the intent of pulling files from an SFTP site and placing them in a folder on the local network.

I am having an issue where the CSP page is catching a JS error. The error in the browser is - A JavaScript exception was caught during execution of HyperEvent: SyntaxError: Unexpected identifier 'downloading'. (However, the unexpected identifier changes after refreshing page, or after removing the Write statement with the work 'downloading' in it.)

I think I have narrowed it down to a piece of the Javascript code - 

0
0 0
Question omer · Nov 24, 2024

I am working on a product that uses REGEX and matches it. 
The regex is tested both on the client-side (using the JavaScript REGEX engine) and both on the server-side.
But I couldn't find one word about the way intersystems parses the regex, It is quite elementary to state which which engine it works with. 
from what I could gather from early implementations and such, the engine is based off PCRE, But I need to confirm this somehow, Can anyone give me a definitive answer, Is there any tool to test the regex other than writing it myself??
 

0
0 0
Article Andrii Mishchenko · Sep 22, 2024 5m read

Introduction

Managing databases and performing CRUD operations are fundamental tasks for developers building data-driven applications. While many database management systems (DBMS) exist, they can be complex and cumbersome to interact with, especially when it comes to creating databases and tables, handling constraints, and performing real-time data operations through an API.

0
0 0
Article Andrii Mishchenko · Sep 27, 2024 4m read

In this article, we’ll dive into the inner workings of the database management tool, exploring the architecture and technologies that power it. Understanding how the application functions behind the scenes will give you insight into its design, how it manages databases, tables, and how the API interacts with data.

We will discuss the core technologies used, including InterSystems IRIS as the primary database and Redis for caching. Additionally, we’ll break down the structure of the tables used and explain how the system handles data creation, retrieval, and manipulation through the REST API.

0
0 0
Question Mark OReilly · Jul 31, 2024

Hi:

I have been adapting the IRIS WHIZ addon as part of the contest. I will soon fork the code on github so the changes are available. 

The next phase is I am storing the date from and to time for a more complete search cache 

zenPage.getComponent(36).value

it works in the chrome console ok 

I'm not sure in external JS how to set the page it is on as a zenpage to use the zenpage functions

0
0 0
Article Alex Alcivar · Jul 27, 2024 7m read

I received some really excellent feedback from a community member on my submission to the Python 2024 contest. I hope its okay if I repost it here:

you build a container more than 5 times the size of pure IRIS

and this takes time

container start is also slow but completes

backend is accessible as described

a production is hanging around

frontend reacts

I fail to understand what is intended to show

the explanation is meant for experts other than me

The submission is here: https://openexchange.intersystems.com/package/IRIS-RAG-App

0
0 0
Question Alin Soare · May 30, 2024

Hi, 

I almost managed to connect myself from nodejs to IRIS via intersystems-iris-native, but the connection failed. 

> const irisnative = require('./intersystems-iris-native')
> irisnative
{
  createConnection: [Function (anonymous)],
  Connection: [Function: Connection],
  Iris: [Function: Iris],
  Iterator: [Function: Iterator],
  IRISList: [Function: IRISList]
}
.....
>     var connection = irisnative.createConnection({
...     host: ip,
...     port: port,
...     ns: namespace,
...     user: username,
...     pwd: password
...     })
Uncaught Error: 8-bit servers are not supported [ERROR_8BIT_SERVER]
>

 

0
0 0
Announcement Rob Tweed · Apr 5, 2024

Hot on the heels of our announcement last week about our ultra-high-performance mg-dbx-napi JavaScript interface for IRIS, we are now pleased to announce a significant new technology - mg_web - which not only represents a new paradigm for JavaScript Web Frameworks, but also delivers significantly higher performance than even the fastest of the established Node.js Web Frameworks, whilst leveraging all the benefits of the big-three industry-standard Web Servers.

0
0 273
Announcement Rob Tweed · Sep 28, 2022

I'd like to announce the release of something really rather interesting - revolutionary in fact.  That may sound like hyperbole, but I don't think you'll have seen anything quite like this, or even thought it possible!

We've pushed out a new JavaScript/Node.js module named glsdb which you can read all about here in detail:

https://github.com/robtweed/glsdb

However, for the purposes of this announcement here, I just want to focus on one part of glsdb: its APIs that abstract IRIS (or Cache) Classes as equivalent JavaScript Objects.

7
1 376
Announcement Rob Tweed · Mar 26, 2024

You may have heard about our mg-dbx-napi interface for IRIS which provides insanely fast access from Node.js.  If you've been following recent developments in the server-side JavaScript world, you'll be excited to know that mg-dbx-napi also works with Bun.js, the latter proving to be significantly faster than Node.js for many/most purposes.

Of course, if you're a Node.js user, you'll probably wonder how mg-dbx-napi compares with the Native API for Node.js that is included with IRIS.

With all that in mind, we've created a Github repository: mg-showcase

0
0 256
Article Lily Taub · Mar 19, 2019 9m read

Intro

Most server-client communication on the web is based on a request and response structure. The client sends a request to the server and the server responds to this request. The WebSocket protocol provides a two-way channel of communication between a server and client, allowing servers to send messages to clients without first receiving a request. For more information on the WebSocket protocol and its implementation in InterSystems IRIS, see the links below.

7
3 6042
Question Dmitrii Baranov · Feb 26, 2024

IRIS is known to have a built-in Python bridge and even allows you to write Python server code but what about JavaScript? Let's say I need a JavaScript expression interpreter. What would you recommend as the most effective way to get one? It is highly desirable that the solution does not require administrator privileges and uses in-process communication (I mean not http and not unix-specific interprocess-communication via command line)

0
0 194