We are getting CoClass not available [80040111] when using %Net.SSH.Session. Does anyone know if there is a security setting that would disable this object?
Any help would be greatly appreciated.
InterSystems ObjectScript is a scripting language to operate with data using any data model of InterSystems Data Platform (Objects, Relational, Key-Value, Document, Globals) and to develop business logic for serverside applications on InterSystems Data Platform.
We are getting CoClass not available [80040111] when using %Net.SSH.Session. Does anyone know if there is a security setting that would disable this object?
Any help would be greatly appreciated.
Dear All,
I'm looping through a list with characters (Parenthesis, square brackets etc) and I wish to remove these from the list.
The for loop and IF logic are effectively removing these items from a list.
However the variable I use for the maximum number of loops carries on beyond the number of items of the list after removal.
In the output value for these I get the integer of the for loop instead of a null for the empty list fields.
I can see in the documentation that the end variable is not editable once the loop is started.
Hi
Sometimes I search mesage with inappropriate sql, It caused query hanged long time.
So Is it have way to find these hanged query and kill it?
Tks.
If you define a Persistent Class / Table the class compiler generates for you an appropriate Storage definition.
A different option is to define a SQL mapping for an already existing Global storage. This has been excellently
explained already in a different series of articles. The Art of Mapping Globals to Classes 1 of 3
Hi!
I believe the simplest is (to work with csv delimited by ";"):
set file = ##class(%File).%New( "data.csv" )
set sc = file.Open( "R" )
if $$$ISERR(sc) quit ; or do smth
while 'file.AtEnd {
set str=file.ReadLine()
for i=1:1:$length( str, ";" ) {
set id=$piece( str, ";" ,i )
write !, id // or do smth
}
}
do file.Close()
Possible options:
different variants of error handling with sc code.
Embrace while loop into try/catch block.
And what's yours?
Hi Developers,
Please welcome another "Coding Talk" video specially recorded for the second IRIS Programming Contest:
⏯ How to Build, Test and Publish ZPM Package with REST Application for InterSystems IRIS
I’m excited to announce that InterSystems will be joining the open source community for InterSystems ObjectScript extension to Visual Studio Code. Early this year I posted that we were on a journey to redefine the future of our IDE strategy, and what came out of that is Visual Studio Code is the IDE that can support that future.
Due to bussiness requirements.I want to add some bussiness field on intersystem message view ui .
eg:
1. add new action page to display bussiness detail
2. add new function to do more Fine-grained things.
3. add new database field in message table.
finally, I hope get more detail of messae view due to customize it.
Tks.
Surely there is an easy way to invoke a ClassMethod from a DeepSee detail listing line, in a similar way to launching a URL. In this case I need to do a little preprocessing of a request adding a SAML token.
I thought I knew how to do it long ago, but I can't read my faded notes on that old parchment.
-Kevin
Hope most of you already familiar with project CachéQuality from @Daniel.Tamajon. For those who don’t know about it, it is a static syntax analyzer for your code written for InterSystems products. It may help you to find and solve many different types of issues in your code, and even possible bugs before clients will find it in production. So, with help of CachéQuality you will be able to deliver a better product. You can find the complete list of rules used to check ObjectScript code here.
It was already available in Studio. And now it is also available in VSCode.
Some weeks ago, I was reading a book by Stephen Hawking and Leonard Mlodinow, The Grand Design. At a certain point, trying to define why do we exist? , why do we use the models we use in physics?, ...those kind of things you know... they pointed at the Game of Life example invented by the mathematician John Coward in 1970... Basically he wanted to show that a system with really basic fundamental laws (Physics) could evolve and "live" to become a more complex system (Chemistry) in which "something" (humans) could work out its own model and complex rules to explain its reality… the rules for this deterministic model that he exposed were so basic that I thought it could be funny to implement them in ObjectScript when I had some spare time... there are others implementations in JavaScript and other languages... but not in ObjectScript... and that had to be corrected!!… so here you are!
Hi Community!
We are glad to invite every developer who uses ObjectSript and VSCode plugin to the upcoming "Introduction to VSCode-ObjectScript" webinar on April 14, 2020 at 11:00 EDT.
Speaker: @Dmitry Maslennikov, InterSystems Developers Advocate, CTO at CaretDev.
You will learn how convenient the development process can be already right now and what we are going to do next to make it even better.
Please check the agenda below.
Hello all,
I'm new to the Intersystems development world and I've been trying to figure out how to make a REST API using ObjectScript. I found a tutorial that I've been following that has been great and I'm trying to translate what I've learned to live data.
My question is "Is there a way I can set a variable inside of a class so when I call a routine that variable will be recognized?" I'm capable of setting the variable in a terminal session and then calling the routine and everything will be work great! I will get the data I want returned.
Hi everyone,
Are there any tools to check the code coverage and to do a lint check for cache object script? Developers will be working with HealthConnect (IRIS based)
Thanks.
Hello!
This may seem a bit strange, but I'd like to make a business operation which would put a file via SFTP and then confirm that the filesize on the remote server is consistent with expectations. I am thinking either of a custom copy or extension of the adapter (right now it is using EnsLib.FTP.OutboundAdapter) that overwrites method PutStream, or a version of the FTP.PassThroughOperation with a customized method OnMessage that does the check after the PutStream completes OK-- but I am uncertain of how exactly to modify either method to make the check.
Hello community,
I recently started to work with Ensemble. I defined a subclass of EnsLib.HL7.Message. In my production I receive HL7v2 messages and transport them using the Message Router to a business operation. The operation class has an OnMessage method with parameter
pObject As MySubclassOfEnsLibHL7Message.
I expected that specifying the parameter type, on receiving the message an implicit type cast would be performed. However, $CLASSNAME reveals that my messages are still of type EnsLib.HL7.Message. How can I convert my messages in ObjectScript (without DTLs or something the like)?
IRIS 2010.1 brought us a new feature: %Net.WebSocket.Client
As a continuation of my series of WS Clients I just couldn't resist to try it.
Well, this is the result and it was rather simple in the end.
You basically need to prepare 3 classes:
The example uses the WSS.EchoServer (a derivate from former SAMPLES in Caché).
The default assumption is to have Client and Server on the same system & namespace.
Hi Developers!
InterSystems Online Programming Contest is over. Thank you all for participating in our IRIS Competition!
As a result - 20 great apps! And now it's time to announce the winners!
I know that collection is instance of %AbstractList.
But what about $listbuild? Does it possible to detect that given variable is instance of $lb?
Hi Community!
The registration phase for InterSystems Online Programming Contest ends today and we will start the voting week!
Now we have 20 applications - so you have a set of applications to choose from!
How to vote?
This is easy: you will have one vote, and your vote goes either in Experts nomination or in Community nomination.
This code snippet changes all passwords in a system to a specified string. The two literal strings at the beginning of the snippet can be adjusted to edit the system or password string. The class method "test" runs the code:
Class eduardlebedyuk.changePasswords Extends %RegisteredObject
{
ClassMethod test()
{
set ns = $namespace
zn "%SYS"
set NewPass = "NewPassString"
set rs=##Class(%ResultSet).%New("Security.Users:List")
set st = rs.Execute()
while rs.Next() { set st=$SYSTEM.Security.ChangePassword(rs.
DISCLAIMER: I am not an InterSystems engineer or a professional ObjectScript developer.
I just want to share my opinion about some things I am really miss in ObjectScript.
I really appreciate everyone who support my project (Declarative ObjectScript) in contest
but the post is not about "why you should support me" on contest.
I faced with ObjectScript in the university while was working on my diploma (in 2013).
Very good mentor @Evgeny Shvarov helped me to get started with ObjectScript development.
Hey Developers,
New "Coding Talk" video was specially recorded by @Maks Atygaev for the IRIS Programming Contest:
Hello,
We have been reasearching how could we parse a string with a JSON structure like the following:
{"code":200,"type":"Consulta","message":"Operacion correcta","result":[{"id":38802130,"paciente":null,"prestacion":{"codigo":"1.
The common requirement in many applications is logging of data changes in a database - which data has changed, who changed them and when (audit logging). There are many articles about this question and there are different approaches on how to do that in Caché.
I'm sharing a mechanism that can help you implement your framework to track and record data changes. This mechanism creates a trigger through an "objectgenarator" method once your persistent class inherits from the "Audit Abstract Class" (Sample.AuditBase). Since your persistent class inherits Sample.
Hello,
We are developing a method to take two messages which have a list of data types. It is being defined as:
{
Property informacion As EsquemasDatos.HistoriaClinica.Informacion;
Property datos As list Of EsquemasDatos.HistoriaClinica.ConsultaCitas;
Property error As EsquemasDatos.HistoriaClinica.Error;
}
Inside datos we have:
Hello,
We are developing a Transformation and we are wondering: how could we debug and show a XML message which is being an output from a transformation, without storing it into request/response/callrequest/callresponse? We mean, how could we show a context variable in the production?
For example, let's have a transformation which stores an appointment in a variable called: context.especializadasConFormatoPrimarias
How could we show in the Production?
Hello,
We have a tranformation where we would like to convert a date from the following format:
"'dd/mm/yyyy' 'hh:mm'" (double quotes are just visual to indicate this is a string)
to date and time separated:
date: dd/mm/yyyy
time: hh:mm
We have already splitted the datetime into date and hour as follows:
set fechaHora = source.result.GetAt(indice).We have a data transformation where source is object collection (populated from a json file) and target is EnsLib.EDI.XML.Document.
If source file is large enough, transformation fails and we get <store> error and I quickly found this:
https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cls?KEY=EBPLR_DTL_foreach which at the bottom in "Avoiding <STORE> Errors with Large Messages" section tells to:
"As you loop over segments in a message or object collections, they are brought into memory.
Hey Developers,
New "Coding Talk" video was specially recorded by @Evgeny Shvarov for the IRIS Programming Contest:
⏯ How to Create and Submit an Application for InterSystems IRIS Online Programming Contest 2020