Trying to create a new SQL Storage map on existing cache Global in the following format - ^MYGLO("R",rec)=data where the 'data' is built using $zel. e.g. $zel(data,1)="p1", $zel(data,2)="p2" etc... and the ^MYGLO("R",123)=data.
I'm having 2 issues.
InterSystems Caché is a multi-model DBMS and application server. See more details here.
Trying to create a new SQL Storage map on existing cache Global in the following format - ^MYGLO("R",rec)=data where the 'data' is built using $zel. e.g. $zel(data,1)="p1", $zel(data,2)="p2" etc... and the ^MYGLO("R",123)=data.
I'm having 2 issues.
Recently, I replaced my old laptop with a new one and had to migrate all my data. I was looking for a guide but couldn’t find anything that explained in detail how to migrate server connections from InterSystems Studio and Visual Studio Code from one PC to another. Simply reinstalling the tools is not enough, and migrating all the connections manually seemed like a waste of time. In the end, I managed to solve the problem, and this article explains how.
Migrating Studio connections was the most challenging part.
Someone, please point me to the location of the cache ODBC drivers, as I only found IRIS ODBC drivers.
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.
In the Caché database, when calculating the total count based on the unique identifier of a record, the quantity is over 1.2 million. After removing duplicates based on the unique identifier and then calculating the total count, the quantity is over 400,000. When grouping by the unique identifier, it can be observed that the count for this identifier is not one. However, when performing a conditional query based on the identifier, only one record can be retrieved. Why is this the case?
Hi all,
I’m running into an issue with a %ZEN.Component.tablePane in a Zen page.
We have:
SearchMessages) that accepts multiple filter parametersWe’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().
The problem is that the table does not update at all Old rows remain, or sometimes nothing appears.
For example, you start debugging the AAA function, which calls the BBB function, then goes to the CCC^ABC function in a different routine and ends up while executing XXX^XYZ. No other routines or functions are visited in this example. What I would like is to get the record of AAA -> BBB -> CCC^ABC -> XXX^XYZ. No marking each function with recording code should be involved: too time consuming, too many functions in real code.
UPD: Iris has built in %SYS.Trace for this purpose but this class is apparently absent in Cache 2017. Did not find any substitutes yet.
I have a personal copy of Cache which I use to help me with certain things. The instance resides on my Windows desktop. The apps I use a web enabled. It would be great if I could access my apps via web browser from my laptop without having to keep a copy of Cache on my laptop. It would make it difficult to keep the databases synced. So, if I restart my Cache instance, then I can use get to my apps by entering the url: http://ipadd:57772/csp/user/myapp.cls. but later, after having closed the browser on my laptop, if I try to open a browser session on my desktop I get license limit exceeded.
Hello Community,
I'm currently planning a system upgrade from Caché (2018.1.8.766) to InterSystems IRIS (2024.1). The environment consists of one database server and three application servers connected via ECP.
I’m considering two possible upgrade approaches:
I am writing a little app where I press a button on a Zen form. It calls a ZenMethod that uses zenPage.launchPopupWindow() to provide me a way to choose a file. I then click on an upload button that calls a csp cache language script file that runs on the server, that grabs the contents of the file and stuffs it into a global. I want it then close and return to the parent window to continue processing the contents of the file.
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.
Our role sits right in the middle.
Here's a practical example of how to import data from a CSV file into InterSystems CACHÉ using ObjectScript
Assuming your CSV file is simple (e.g., comma-separated, with headers), you can use %Stream.FileCharacter to read it line by line and parse the data.
ClassMethod ImportCSV(filePath As %String) As %Status {
Set stream = ##class(%Stream.FileCharacter).%New()
Set sc = stream.LinkToFile(filePath)
If 'sc Quit sc
While 'stream.AtEnd {
Set line = stream.
If you are investigating complex structured Globals this can become
a rather boring typing exercise. Different from Global Explorer in
System Management Portal Global-Inspector allows a kind of drill-down
to dig deeper and deeper by subscript levels.
You also have the option to see the stored content or to show only
the subscript structures.
Globals storing SQL Tables are probably not so thrilling, but in SYSTEM
space you find real trees with completely different branches and twigs.
Global-Inspector can run in browser or from terminal command line.
Hi,
I have a code that copy a method to another class for analysis purpose.
I also want this method to appear first in the source code to easily use it in VSCode with the classmethod debug button and not search it in the numerous method of the modified class.
Is there a way to do such a thing?
I tried the placeAfter keyword but I can't find a way to make it really work as I want. Is their other ways to control the order of methods?
Alex Koblov posted today a #CachéHaiku:
Full command names Make your code more readable Than compact versions
My haiku:
Caché Globals Shows you keys to the value If you $order it
Your variant? ;)
Hello to all the Cache Experts out there and Happy Friday!
The company I work for uses Cache 2017.1.3 and we have been seeing intermittent errors in the Cache Error Trap when an SQL query runs. The error message looks like the error is occurring within the cached query routine that Cache auto-generates. Unfortunately, when I pulled up the routine in the SMP System Explorer, I only found an obj version, so was unable to look at any code.
Here is the error: Note: the .
You can check the free disk space at any time using the system utility class: SYS.Database and query: FreeSpace.
Here's how to try it in the IRIS terminal (go to the %SYS namespace and then run it):
zn"%SYS"set stmt=##class(%SQL.Statement).%New()
set st=stmt.%PrepareClassQuery("SYS.Database","FreeSpace")
set rset=stmt.%Execute()
do rset.%Display()The output result example is as follows:
*In the command execution example, all databases are located on the same disk, so the free disk space (DiskFreeSpace) returns the same value.
Are you curious about how to run Python scripts directly in your InterSystems IRIS or Caché terminal? 🤔 Good news it's easy! 😆 IRIS supports Embedded Python, allowing you to use Python interactively within its terminal environment.
How to access the Python Shell?
To launch the Python shell from the IRIS terminal, simply run the following command:
do##class(%SYS.Python).Shell()This opens an interactive Python shell inside the IRIS terminal. From here, you can write and run Python code just as you would in a normal Python environment.
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.
I'm following this guide as well as the sample.cs file and getting an error message on this linecache_connection.Connect();
The error is:Caught GlobalsException: lc_conn::connect_device returned Db_err: source: lc_conn::connect() message: lc_conn::connect: CacheSecureStart returned -15: <ACCESSDENIED>
I've tried many variations of Namespace + Username + Password and they all result in that error, even though I can connect to the namespace just fine using other means.
Until now i used $ZF(-1), in older Caché versión, now I try to use $ZF(-100), i do:
REST>w $ZV Cache for Windows (x86-64) 2018.1.4 (Build 505_1) Thu May 28 2020 10:12:49 EDT REST>s a=$zf(-100,"/SHELL","dir") S a=$ZF(-100,"/SHELL","dir") ^ <NOTOPEN>
What is wrong?
Thanks in advance
I'm trying to print from Cache and I have setup the device, but keep getting a message that someone else is using it. this is RHEL 7.9. I have cups running and I can print from the command line. I have also issued this command: lpadmin -p KM501L -u allow:all
what am I missing
thanks
Paul
Based in the US for a fully remote, permanent role. Applicants must have development/programming experience with Cache Object Script language.
Contact:
Matthew Churchill, matt.churchill@arcaresourcing.com
I recently started trying out Python in IRIS, but now I get this message repeated over and over again:
^Sources is not setup so hooks will not work
No idea where this came from and how it started. Any suggestions?
I like Application Error Log a lot, both for its full stack and a big list of variables. I'd like to "hack" this functionality and record the same in this log when a certain variable has a certain value. This quasi error should not be visible to the user, and it should not interrupt the application flow. Is that possible?
Throwing an error in a try-catch block does not record the error, tested. I am considering recording variables and the stack differently, I know how to do both, but that would miss the nice Application Error Log functionality.
Upd: I got an immediate DC AI Bot reply.
I am trying to get the value of a Submit button on a CSP object page.
<input type="Submit" value="Assign" name="action" id="action">
I tried getting it thru $GET(%Request.Data("action")), but it throws an Undefined error. Isnt $GET supposed to handle it if its undefined anyway?
How do I get the "value" of the button pushed when the form is set to POST?
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.
Is there a recommended way or best practice in IRIS to automatically clear or bypass the browser cache for JavaScript?
Is it possible to audit code changes in a namespace?
Ideally what we'd like to be able to do is check which classes were compiled (or deleted) in a time period, eg in last 3 months, and which user made those changes. Even better would be an audit of what those changes were, but that's less important (for us, as we can probably find that information in other ways).
We have a service where 3 groups, each with multiple users, potentially have access to make changes to the live service. With the best will in the world, each group doesn't always tell every other group about changes made.
Can someone point me to learning resources / documentation for Intersystems Terminal? I have scoured YouTube, Intersystems documentation, and the internet. Many of the Object Script commands I found don't work (and that are listed here) do not work in the version of terminal that I have:
https://docs.intersystems.com/ens201817/csp/docbook/DocBook.UI.Page.cls…
So far, I have only found 1 YouTube video that presented commands that 'actually' work my Cache terminal install:
https://www.youtube.com/watch?v=F3lw-2kGY6U&list=PLp4xNHWZ7IQmiSsryS0T3…