Hi community,

I need to write an SQL query to fetch a random record from a table, that table has millions of data.

In postgresql, for example, there is a RANDOM() function to do something like that:

SELECT column FROM table
ORDER BY RANDOM()
LIMIT 1

Is it possible to do something like that in Caché?

Thanks in advance

0 8
0 634

Hi,

A device is sending me HL7 messages (ORM^O01)

the framing is set to "None"

and i get the following error:

3 Segments
Build Map Status = 'ERROR <EnsEDI>ErrMapRequired: Missing required PID element at segment 2 (PID)'
'ERROR <EnsEDI>ErrMapRequired: Missing required OBR element at segment 2 (PID)'
'ERROR <EnsEDI>ErrMapSegUnrecog: Unrecognized Segment 2:'PID' found after segment 1 (MSH)'

i seems that there framing chars in at the beginning and end of each segment

(in Hex)

0 3
0 626

I need to set and use some context variables in a transformation (written in DTL), but the code is manually written.

When writing the same as BPL I define context variables and they are visible in transformations called by that process.

In something like this my.DTLtransform sets HL7 message fields to values in context variables:

0 11
1 623
Question
· Dec 9, 2020
Code migration using VSCode

I am fairly new to using VSCode. I have used VSCode to create some files on our Test Server, now I need to move them to Production.

Looking through the VSCode extension documentation, maybe I missed it but how to I migrate code from one workspace to another. In Studio I was use to exporting the code into an XML and just being able to import it on the Production server version of Studio.

Thanks

Scott

0 9
0 618

Hello Community,

I want to secure a SOAP Webservice (an EnsLib.SOAP.Service one, if that matters) adding a SSL/Username Policy to it. As im not sure how detailed my request here should get, ill try giving a detailed as-is description of my setup, what I've tried, how I tried to test the connection and what problems including some logs I ran into.

As a small foreword: I'm pretty new to the whole security aspect of intersystems and soap itself.

System:

1 3
0 613

Hi all,

I need some advice about JSON conversions and the outputs. I am being sent a JSON response from an API call and I am struggling to produce an output that I can use from it.

I have used the %FromJSON() method call to take the JSON stream source (pData) and convert it to a Dynamic object (object) but I am a little unsure as to how I can read the dynamic object and use it to extract the values from this and set the values as a property in another class.

The current coding I have for the conversion:

0 21
0 612

Hello,

I am trying to create a HL7 message (REF_I12 message) using variables extracted from a Dynamic Object and need some advice about segment creation issues that I am having. Some background info: I receive a JSON response from an API call and used %FromJSON to convert the response to an Dynamic Object. Some of the items in the response are repeated such as NOKName, NOKrelationship.

0 3
0 609

Hello,

We would like help to know why our web service which gets Patient's ID number, does not accept messages?

We observe its Event Log, and it contains the following pattern:

We detail each log to give info to discover what's happening:

First there is a new connection:

Then it suddenly disconnects

After that it looks like the service restarts:

0 3
0 608

Created a record map to read a flat-file of lab results.

Have multiple lines that represent result components for a given order per pt MRN.

Grouping these records together based upon the order number in a custom service to create a single XML message.

Within the XML message, there are some fields that occur once and some that occur one or more times.

Within the record map, the fields/properties that occur once are configured as "As %String. The fields/properties that occur more than once are configured as "As List of %String.

0 8
1 606
Question
· Oct 29, 2020
Reply with custom ACK

Hi,i have created a simple production with:

Business Service-EnsLib.HL7.Adapter.TCPInboundAdapter

Business Process - EnsLib.HL7.MsgRouter.RoutingEngine

Business Operation - EnsLib.SQL.OutboundAdapter

the sending application requires a ACK wich is different than the ACK i choose from in the AckMode settings of the Business Service.

How do i create a custom ACK?

Thanks

0 4
0 605
Question
· Jul 6, 2020
Ensemble does not start

Hi Team,

When I tried to open ensemble in my system I got bellow error.

I have done lots of code in my local system but now not able to open the ensemble.

0 8
0 603

Hi,

In Atelier I can click File --> New --> Class File, and File --> New --> Custom File etc to launch various wizards and templates to help me quickly create DeepSee KPI classes, %Installer manifests, Web Services and the like. Of course, all these are available through Studio as well. Is there anything similar in VSCode? If so where? I've looked at several videos and the documentation, but I haven't seen anything.

Thanks!

David

2 3
0 597

I am working on a BPL to take data from a MS SQL database and create an HL7 Materials Message for our EMR. I have done this plenty of times in the past however I am running into an error.

"Remote Gateway Error: JDBC Gateway SP execute(0) error 0: Access to the remote server is denied because no login-mapping exists."

What is confusing is that this BPL doesn't differ from any of my other BPLs in connecting to MS SQL Server. I know I am missing something..

0 3
0 597

Hi community!

Is it possible generate HTML documentation to my project ObjectScript classes (.cls)?

In Java we use Javadoc to do it. Javadoc get class comments and java metadata information and when I execute javadoc -d doc src\*, I get whole html documentation to my classes. Has IRIS something like javadoc? Is it documatic? If yes, how can I use it?

1 12
2 597

Hello,

We are wondering how could we iterate over a segments list,

The use case is that we are sending from Process X to process Y a message, only if at the OBR4 CE1 there is a certain code. We were getting this field as follows:

set context.studyReason = request.GetValueAt("ORCgrp(1).OBRuniongrp.OBRunion.OBR:UniversalServiceIdentifier.Identifier")

How could we iterate over the following message and get both OBR4 CE1 (1 and 2):

0 2
0 588

Just like the title says, I'm attempting to find a way to create a web application that instead of serving CSP files, it uses a dispatch class.
I searched for clues in the documentation, but the CSPApplication tag seems to be exclusively for CSP file-based applications.

I'm trying to avoid implementing a workaround such as using the Invoke tag to call the Security.Applications to generate the web application but I might be forced to do so, even though it's unpleasant if I had to say...

So, is there an official way to execute this task?

1 22
0 587

Hey everyone.

I have noticed that my backup mirror is warning that the MirrorDatabaseLatencyTime is having a bad time (time in ms is 3000, and warnvalue is 3000). While I look into what may be causing this latency between the two servers, I was considering if reducing the size of the journal files would improve this value in any way.

My assumption is that reducing the file size would mean that the frequency of the journal files being created would be increased, but the reduced size would mean that the transfer and application of each file would be reduced.

0 2
0 583

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.

0 7
0 583
Question
· Feb 19, 2020
Disabling Telnet

Good Day;

looking at disabling Telnet - on Windows - Cache 2012,2017. The security scans don't need it on network.

But still leave users able to use `Terminal - direct - on the box should be fine.

am posting here for quick refs (as this is a common security vulnerability out there).

Regards;

Anzelem.

0 5
0 579

Hello,

We would like to learn how would you approach this task.

We would need to check every day a set of folders which are outside our server (in fact we could see them as if they were "inside" the server), then we need to check for modified or created files in the last day, and move all the ones which match the criteria to just one folder in our server.

We have thought about doing the following:

1) Create a task to run it each day:

0 5
0 578

Hi,

We are using CACHE 2017.2.1, I would like to retrieve data from Journal for killed global. Let say we have global name ^ EMP(123) with data and also have some child nodes and it has been killed by using cache kill command for some reason and we don't know who has executed this and when. My questions are below.

1) Can we get back the data of killed global from journal files,Is it possible or not ?

0 5
0 574
Question
· Mar 26, 2020
Merge two lists?

Hello,

We are developing a method to take two messages which have a list of data types. It is being defined as:

Class Mensajes.Response.HistoriaClinica.ConsultaCitasResponse Extends Ens.Response [ ProcedureBlock ]
{

0 1
0 573