We are currently looking into a way to provide a group of end-users (i.e. non-Interface Development engineers) access to a pre-defined group of Ensemble-based Data Lookup Tables for purposes of viewing and editing. We do not want to give them access to ALL Data Lookup Tables due to security/continuity concerns.

My thinking is that a simple persistent Cache table with three columns (Role Name,  Table Name, Access-Level [like View or Edit]) with a CSP front-end could potentially provide an easy way to make this solution a reality.

I heard some discussion at the Conference last week that a code sample may already be available to give us a jump start in this direction but I have not been successful in locating one. Is anyone anywhere of such a sample or perhaps has delved into this themselves that might be willing to share a little context in how it could be accomplished? I am relatively new to Cache/Object Script/CSP development but eager to get my feet wet.

Last answer 29 April 2016
0   0 2
0

comments

529

views

0

rating

What would be the preferred method to create an HL7 message from an input that is not HL7?

Would it be better to take the non-HL7 input and construct an HL7 message in the business service that then gets passed off to a routing process, or would it be best to just pass the non HL7 message to a routing process that called a data transformation to create the HL7 message?

My thought is the later, due to the fact that updates to the creation of the HL7 message are done using the graphical DTL editor rather than editing COS in the service.

 

Last comment 29 April 2016
0   0 2
0

answers

310

views

0

rating

I have two servers in our TEST environment.  One with HSBUS and one with HSREGISTRY.  Let's call them "HSBUS01" and "HSDB01" respectively.

 

Now, I can access HSBUS with my SQL client by using the JDBC driver pointed to hsbus01.full.name.com and port 1972 and specifying a namespace of "HSBUS".  I am, however, unable to access the HSREGISTRY instance via SQL with a similar combination of information.

I have access to the web interface on both servers (/csp/sys/#CSP.Portal.Home.zen).  What screen can I use to compare the relevant settings?  I think it might be a port issue.  Where would I find that?

Last answer 28 April 2016 Last comment 29 April 2016
0   0 3
217

views

0

rating

We have a query that looks something like:

 

select a, b, c, d, e, f

from tbla inner join tblb on tbla.....

This query runs in the expected 200-400 ms range.

If we run the same query but reduce the select to just:

select a

from tbla inner join tblb on tbla.....

then the query runs for 30 minutes or more. 

The rest of the query is identical.  Is there a logical explanation for how this can happen?

Thanks.

Last answer 28 April 2016 Last comment 29 April 2016
0   0 2
325

views

0

rating

I have to disect thousands upon thousands of strings like this:

96842-2-AEV.00001-63561-001958-100728760I-42

I've been able to pull out the first, second and final segments as separated by hyphens, but now I have a predicament where I need to use the second segment, the 2 shown in the example above, in a join to another table.  Problem is Cache apparently doesn't like doing that.  Just the same, I have to find a way.

Here's the code I'm using to pull that segment out into as separate field in the query results:

substring(prov_record_id, charindex('-', prov_record_id) +1, charindex('-AEV.', prov_record_id) - charindex('-', prov_record_id) - 1

Last answer 28 April 2016 Last comment 28 April 2016
0   0 1
553

views

0

rating

Hi Community,

How can I create a JSON with the object ID by using the %Object:$toJSON API?

I have the following piece of code bellow where I create an object reference, create a %Object instance from %fromObject and them I am creating the JSON from $toJSON, but it does not expose the %ID (object id). How is the best approach to create a JSON with the respectives object IDs?

Last answer 15 April 2016 Last comment 27 April 2016
+ 1   0 2
926

views

+ 1

rating

I would like to know how to close a dropdown list after selection, and also how to set the selected value to the list first to be displayed.

I can get the value by clicking the dropdown but not back to the initial state and also does not display the selected


Thanks

Last answer 27 April 2016 Last comment 27 April 2016
0   0 2
1263

views

0

rating


I'm trying to find a good way to control the Filename for X12 Acknowledgement files, but there doesn't seem to be a way to do that without custom coding.  Here's what I figured out so far:

EnsLib.EDI.X12.Service.FileService allows you to set a Reply Target Config, which would likely be an X12 File Operation.  The Service doesn’t have any settings related to the name of the Acknowledgement file though.  That’s determined entirely by the Operation.

The Operation allows the outbound filename to be derived from the X12 Document’s Source property, by including %f in the File Name spec.  The Source property is something you can set, such as in a DTL, but the File Service doesn’t set it when generating the Reply document.

The result is that Reply files consist of a timestamp and unique counter only, as defined by the Operation’s default File Name spec, %f_%Q%!+(_a)

Last comment 27 April 2016
+ 1   0 2
0

answers

298

views

+ 1

rating

Starting with 2016.2 the Java XEP binding will no longer support the in-memory connection mode. The in-memory mode was deprecated in earlier versions and applications should switch to the TCP/IP connection mode instead.

The TCP/IP connection mode has bridged the gap in performance to a large extent over the past couple of years and enables the Java client to run on a remote machine.

Let me know if you have any questions or concerns.

This is a cross-post from our compatibility blog: http://blog.intersystems.com/compatibility/2016/04/22/removal-of-in-memo...

+ 1   0 2
0

comments

155

views

+ 1

rating

Starting off with a working REST interface, I can access the CSP Application definition screen for the application  (System > Security Management > Web Applications > Edit Web Application), and "turn off" the application by clearing the Enabled: [ x ] Application checkbox. From then on my REST calls return an HTTP 404 error. (That's expected).

However - one expects that re-enabling the Application in the CSP Application screen, would return my REST services to a working state, however, this is not happening.  All REST requests continue to return an HTTP 404 error

Last answer 19 April 2016 Last comment 27 April 2016
0   0 1
204

views

0

rating

(Possibly?) little-known fact: It's possible to use $ListBuild on the left hand side of the equals sign in a set command to extract multiple list values at once:

set $ListBuild(several,individual,variables) = list

 

For example:

USER>kill
 
USER>set colors = $ListBuild("red","orange","yellow")
 
USER>set $ListBuild(r,o,y) = colors
 
USER>write r,!,o,!,y,!
red
orange
yellow

 

See for reference: http://docs.intersystems.com/cache20152/csp/docbook/DocBook.UI.Page.cls?...

This feature was news to me - I use $ListBuild lists a lot but hadn't come across it until today. Had anyone else encountered this?

Last comment 27 April 2016
0   0 4
253

views

0

rating

Hello,

Here's the code:


Method isTestClass(className As %String) As %Boolean
{
    if (className = ..#UTCLASS) {
        return 1
    }
    
    #dim c as %Dictionary.ClassDefinition
    #dim status as %Status
        
    set c = ##class(%Dictionary.ClassDefinition).%OpenId(className,,.status)
    
    if ($$$ISERR(status)) {
        throw ##class(%Exception.StatusException).CreateFromStatus(status)
    }
    
    if ('c.SuperIsDefined()) {
        return 0
    }
    
    #dim children
    #dim len as %Integer
    #dim i as %Integer
    
    set children = $listFromString(c.Super, ",")
    set len = $listLength(children)
    
    for i = 1:1:len {
        if ..isTestClass($listGet(children, i)) {
            return 1
        }
    }
    
    return 0
}

One thing which bothers me here is that I do not "close" the %Dictionary.ClassDefinition object; I believe this to be a problem somewhat, is that the case

Last answer 25 April 2016 Last comment 27 April 2016
0   0 1
300

views

0

rating

Hi,

I'm posting this for the benefit of others. Not often one changes certificates in Cache, at least in my case. I run a system, that uses certificates to encrypt SOAP messages, and since the last time I ran it, my certificates expired.

So I renewed them using our PKI tool, so far so good. I gave all (3) certificates the same names (and filenames too) as to those expired, thinking that everything would just work fine next time I call the SOAP service.

Unfortunately, I got trapped.

It took me a rather longer while to realize that replacing old files with new ones is not enough. You also need to DELETE and CREATE again all your X.509 Credentials (with original names) to reflect changes, otherwise our X.509 credentials still remember old certificates with old serial numbers (yes, that's a good indicator saying what certificate is active)

Hope this helps others.

 

Dan

 

 

+ 2   0 1
0

comments

340

views

+ 2

rating

Introduction

If you manage multiple Caché instances across several servers, you may want to be able to execute arbitrary code from one Caché instance on another. System administrators and technical support specialists may also want to run arbitrary code on remote Caché servers. To address these needs, I have developed a special tool called RCE.

In this article, we will discuss what are the typical ways of solving similar tasks and how RCE (Remote Code Execution) can help.

What possible approaches are available?

Execute OS commands locally

Last comment 25 April 2016
+ 2   0 3
1885

views

+ 2

rating

I've been using iFind indices in one of my applications but this morning discovered that the index is missing data. I confirmed the issue also exists in our test environment and rebuilt the indices there. That seems to have fixed the immediate problem. However I'd like to understand how this came about to avoid it happening in the future.

Has anyone encountered this before and know the cause

Last answer 22 April 2016 Last comment 25 April 2016
0   0 1
267

views

0

rating

I installed Atelier on Windows in order to take a look at how the BPL and DTL graphical editors accessible via the "Open diagram editor" action work. The diagram editor is opened but I get the following error:


Message from webpage
---------------------------
Unable to load SVG diagram. Please ensure your browser is supported for portal access.


It looks like Atelier uses IE in order to display the editor even though my Windows default browser is Chrome.

I tried to change the General -> Web Browser setting to "Use external web browser" and choosing Firefox or Default system web browser. However, regardless on this change (and Atelier restart), IE is still used for opening the diagram editor, so it seems that this setting affects some other browser usage.

The same problem affects the browser launched for the Atelier Videos site located on the Overview page

Last answer 22 April 2016 Last comment 25 April 2016
+ 1   0 2
413

views

+ 1

rating

I followed the Documentation instructions to install Caché on my Linux box and it seems to be running fine except when I try to modify the configuration.  I keep getting errors that a previous cache.cpf file (e.g., cache.cpf_8503) cannot be opened.  Is my Linux "user who owns instance" account deficient in Linux permissions?

Last answer 22 April 2016
0   0 1
0

comments

139

views

0

rating

Hi! 

There is a question for Ensemble on Stackoverflow:

I have the below dtl. In the foreach loop, I am just copying the same code in another part under anif condition. How can I avoid this redundancy? Can I reuse using sub transformation?

Here is the dtl class file :https://docs.google.com/document/d/1snJXElyw13hAfb8Lmg5IaySc7md_DE8J40FB79hBaXU/edit?usp=sharing

Original question.

Last answer 16 April 2016 Last comment 22 April 2016
+ 1   0 0
362

views

+ 1

rating

Good afternoon, I have image files stored on disk. I would like to display those images in an <image> control as the end user clicks on rows in a tablepane. I already do this with image data stored in a cache database:

s imageComp = %page.%GetComponentById("ImgTab"_tLdCnt)
s imageComp.disabled=0
s tId=rsId.Get("ID")
s tPageObj=##class(My.PageObj).%OpenId(tId)
s oid=tPageObj.ImageBLOB.%Oid()
s encryptedOid=..Encrypt(oid)
s imageComp.src="%25CSP.StreamServer.cls?STREAMOID="_encryptedOid

 

In this project, I can displayed the image if I set the scrDisabled, scrMissing or src attributes to the full path and file name of the image in XData Contents.

However, the dynamic loading of the <image> control as the end user clicks on rows in a tablepane does not work.

 

I have tried setting the src attribute directly:

s imageComp=%page.%GetComponentById("ImgTab1")
s imageComp.disabled=

Last answer 21 April 2016 Last comment 22 April 2016
0   0 2
362

views

0

rating

Hi this is my first post, so a little about my background. I've been programming in PHP/JavaScript for about 10 years.  
I've got quite a bit of knowledge surrounding object orientated programming and know the basics.

Last year I looked into the Mirth integration engine and did some work around that.

I've now moved jobs and I'm doing some work (surprise, surprise) with Ensemble.

I've done the tutorial and understand the basics of the web 'frontend' and what an integration engine can do. I'm now being asked to write a transformation to take a hl7 message and create a html one which is then base64'ed and outputted to a file.

So at present I've created my service, processor and  output.

Service is very simple Inbound file adapter,  processor that can accept that.

and finally a operation that has a class name of

EnsLib.File.PassthroughOperation

and a adapter of 

EnsLib.File.OutboundAdapte

Last answer 22 April 2016
0   0 1
0

comments

381

views

0

rating

Is is possible in Atelier to open a macro declaration?  Using the context menu results in a "Current text selection does not resolve to a Script element" error in the status area at bottom of window.

Also the arguments for the macro are not shown on hover.

Doesn't seem to matter if the associated include file is added to the project.

(Version: 1.0.142, Mac OS X)

Last answer 22 April 2016
+ 1   0 1
0

comments

210

views

+ 1

rating

It looks like the normal usage of calling an Ensemble based Web Service via Ensemble is to create an Ensemble Business service that inherits from EnsLib.SOAP.Service which is then used to call a business operation which inherits from EnsLib.SOAP.Operation and the SOAP Outbound Adapter which can be generated via the SOAP wizard.

But, what if you don't want the extra step of calling the web service class via the operation? Has anyone actually constructed the Business Service to directly invoke the web service class? I know you lose the ability to trace any messages in this case but I'm wondering if there is a performance optimization doing this.

If anyone has done this and has a simple sample that would also be appreciated. 

Last answer 21 April 2016
0   0 1
0

comments

362

views

0

rating

I tried logging into https://beta.learning.intersystems.com to view a video.  My browser auto filled the login form.  The username, the same one I use here and on many other ISC sites, is "sbeeson_MHCX".  Now I have a message that says "Only lowercase letters allowed" and any time I visit the login form it just shows the same message.  I cannot get back to the form.

I could obviously use an incognito window or clear my cache, but this needs to be fixed.

Last answer 21 April 2016 Last comment 21 April 2016
0   0 3
312

views

0

rating

When refreshing a html or tablePane component using refreshContents() that takes a lot of server-side-processing, I'm running into timeouts every now and then. i.e., the result for the tablePane is that there's nothing displayed at all.

How can we configure (relax) that timeout so also those heavier ones get refreshed eventually? Just overriding %request.Timeout in %OnPreHTTP did not seem to do the trick.

Last comment 21 April 2016
0   0 2
0

answers

312

views

0

rating

The following situation always catches out new Ensemble users, and is likely to continue doing this until it is addressed..

A business operation, service or other host that is configured with a dedicated # of actors, (ie, not using the actor pool) runs with the version of compiled code that existed when the host was started.  This code is loaded in memory. 

Whilst they are running and developers edit and compile lines of code for a business operation, they expect immediate effect, but this does not occur for the aforementioned items, and the only clue that given is an Information event log error saying the host is running a previous (now stale) version of the code

Last answer 21 April 2016
0   0 1
0

comments

241

views

0

rating

Hello,

 

In my project, I am calling a store proc on third party database. I am using SQL Gateway and ODBC. Everything is working fine until the store proc changed.  In store proc they have changed the return alias name for a column. In Ensemble Snapshot I am not seeing the modified alias name until I restarted the whole Healthshare instance.

 

Here is my question, is there any other way? We do not want  to take the instance down if it happens after we go live.

 

Thanks

Raghu

Last answer 21 April 2016
0   0 1
0

comments

316

views

0

rating

Hello community!

Heretofore is announced a new project which aims at providing a usable library for both running unit tests and collecting code coverage information at the same time:

https://github.com/litesolutions/cache-utcov

I shamelessly admit that this is my first project written in ObjectScript; the only source file right now barely loads a %Studio.Project instance on a given namespace and fails ungracefully on failure (it HALTs; meh); and even on success it will not even list the items correctly... Well, that's part of the learning curve.

This project is of course not "innocent": for CachéQuality, we want that information (the result of unit tests and coverage information). But we believe that it is in the interest of a lot of people that a package exists which provides such information in as generic a way as possible

Last comment 21 April 2016
0   0 5
428

views

0

rating