I'm looking for a way to get the message header ID for the current message in a Request to a Business Process.

I've located some code that gives me what I need, but it runs the risk of violating the "abstraction layer" ISC has in place around such things. And while I very much appreciate their efforts at keeping things simple for me ... well, sometimes you just have to dig through the guts to get what you want.

Is there a documented, deprecation-resistant method for getting at %Ensemble("%Process").%PrimaryRequestHeader.%Id() from within a BP?

0 6
0 827

Hi,

I need to read a UTF8 encoded text file and translate the content to 8-bit.

Using %File class and $ZCVT(TXT,"I","UTF8") works , but I see that if the content is larger than max string (32000) and we cut the content

To max string chunks, we can get a <translate> error if we cut it in the "wrong" point..

Is there a better way to do this task?

My code looks like this:

0 10
0 1.8K

Hi All,

Just wondering if anyone had got this working.

In the documentation it says to set the username and password properties of the connection object but these properties don't exist and without authentication I can't connect to the MQ queue.

Any help would be greatly appreciated,

Dave Moss

0 4
0 342

Hi,

I have a global that holds users name and date of birth.

I would like to loop through them and check if the date of birth is more than 2 years based on todays date

so I have ^checker("under2", "Eric David", "02-05-2018")

I want to check the birthdate based on todays date to see if it is greater than 2. How do I access the birthdate in the global

Please can you advice

I tried :

0 9
0 1.2K

Has anyone called any outside Javascript code from inside their class files? I asked a long time ago if there was a way to manipulate an image within Cache Object Script, and since Cache doesn't have any image libraries its not really possible. However I have found Javascript to resize an image and wonder how hard it would be to mesh the two together.

Can anyone share any examples?

Thanks

Scott

2 9
1 1.4K

Hello,

I'm looking to find if there is a datatype convert equivalent in Object Script to SQL convert function. Have a VarBinary string coming in from source application (which is really performing a SQL dump). The source application uses the standard SQL convert function to convert from varchar to varbinary on their side.

I know &sql(Convert()) should work in Object Script, but am wondering if there is a better way of doing this.

Getting data in via flat file (Record Map), then using data transform to transpose this data to SDA3.

0 4
0 685

I have a persistent class that represents cities across the United States. It is below, but basically has a City Id, Name, Lat, Lon and a few other unimportant fields for this issue. Anytime I attempt to query on the Latitude or Longitude it immediately returns no results. My first thought was that it was a casting issue so I tried casting both sides to floats, ints, even strings and in all cases it immediately comes back with no results. I then decided to cast it to a string and attempt a like statement thinking it might be something about how floats are handled, but still no joy. Any

0 2
0 325

Hi

Totally new to IRIS and Cache.

Trying to evaluate it and work out how we could use it.

As a standard application database. Object or relational etc. does not matter.

Issue is ObjectScript.

So:

1) Can we develop, maintain and use an IRIS database and never use ObjectScript i.e. use only Java, Python, C++ interfaces etc. (exactly which one does not matter)? Would that make designing and using the IRIS database more prone to inefficiency and error?

2 4
0 797

I need to write a script to answer a couple of fairly simple questions:

1) What is the current routine DB (name and location) for this namespace?

2) What is the current data DB (name and location) for this namespace?

3) Is global ^ABC mapped to a different location than the default data DB?

Can anyone point me to some system APIs that would allow me to answer these questions?

Thanks!

Ben

0 2
0 439
Question
· Nov 1, 2018
Pattern Match with Cache

I'm trying to interpret a ObjectScript pattern and I am stumped on the first part. I understand everything else but not sure what 1.A means. I know A stands for Alpha characters just not sure what the 1. means

0 3
0 505

Hello,

I am a beginner with Object Script and I hope anyone can help me solving my questions.

1. Is there a way to time a loop in Object Script?

2. My code leads to the following error, even though it executes the method.

Is there a way to ignore this specific error, so that I can repeat my code in a time loop over and over again without stopping?

1 3
1 861
Question
· Sep 28, 2018
Impact of OREF support

There are some classes in our code base that contain Methods only (no properties). I told my colleagues that converting them into the ClassMethods should improve performance as it would eliminate unnecessary OREF support at run-time. Some of them replied that it would be microseconds, so what is the reason to bother.

Is it possible to estimate the impact of OREF support of method calls at run-time? E.g., as a % of all CPU load.

0 12
0 445

Hello Experts,

I have a silly question of using InsertParam method and usage. I understand it is name value pair. I am using GET method to send a url and to get the details from server. URL has multiparameter

URL - api/Identifier/Image/?Verify.EDD={EDD}&Verify.Ethnicity={ETHNICITY}

I have used the URL in a method and called that method directly in the business operation. I am using Insertparam method -

0 1
0 457
Question
· Sep 13, 2018
Operators as Variables

We have the need to write a function that can loop through say a field in an OBX segment within HL7 and compare it to a string passed. Is it possible to have the user enter the Operator ( >,<,=,<>) as a variable inside Cache object script? Does anyone have any examples they can share?

Thanks

Scott Roth

The Ohio State University Wexner Medical Center

0 8
0 484
Question
· Sep 6, 2018
list Of %String problem

I am trying to initialize a list of %string property to an empty list, and after add eleements.

d ##class(Test.Test).Test("hello") ; works perfectly
d ##class(Test.Test).Test("") ; does not work, the list stays empty

How can I do that. Thank you so much

0 1
0 521

Hi,

I have a routing rule that calls some utility classmethods, but for some reason the compiled version insists on linking to a utility function in a different package.

The call to 'SendToEaling(HL7)' in isn't compiling to a call to the LNWTIEPackage as expected:

##class(LNWTIEPackage.RoutingRules.Utility).SendToEaling((pContext.HL7))

but is instead becoming a call to the LNWDeploy package

0 5
1 366

Hello Everyone,

I was wondering about the best way to initialize several variables, or several lists of variables.

Would it be better to write it like:

set (var1, var2, var3) = "value1"
set (var4, var5) = "value2"
set (var6,var7,var8) = "value3"

or

set var1="value1", var2="value1", var3="value1", var4="value2", var5="value2", var6="value3", var7="value3", var8="value3"

or

0 6
0 441