#Caché

30 Followers · 4.5K Posts

  

InterSystems Caché is a multi-model DBMS and application server. See more details here.

Documentation.

Question Laura Cavanaugh · Oct 12, 2017

I'm trying to write an installer manifest that can create a namespace, resources (%DB_namespace) and a role (with the resource, above), based on the namespace.  So you could pass in "ABC", or "XYZ", and it would create the %DB_ABC resource and the ABC role with %DB_ABC:RW permissions; or it will create the %DB_XYZ resource and the XYZ role with %DB_XYZ:RW permissions, accordingly.

I have a variable set up for the name of the namespace (in my code it's called PMGNAMESPACE), and I create a variable for the resource name, called PMGDbResource ( this == %DB_ABC)

2
0 430
Question Mike Dawson · Oct 11, 2017

Hi Community,

Has anyone ever set up a web service that takes a stream data type as an argument? The client will be dotNet.

This is the error I see:-

   <SOAP-ENV:Fault>
      <faultcode>SOAP-ENV:Client</faultcode>
      <faultstring>Badly formed SOAP Message</faultstring>
      <detail>
    <error xmlns='http://soap.rmh.nhs.uk'&gt;
     <text>ERROR #5002: Cache error: &lt;INVALID OREF&gt;XMLLOOP+9^WebService.eDCGold.GetRootKeyLocalRef.1</text>
    </error>
</detail>
    </SOAP-ENV:Fault>

2
0 1182
Question Sebastian Mueller · Oct 5, 2017

Hi everyone,

I really like using dynamic objects and dynamic arrays, Usually ending up with an SQL query that returns a JSON object i throw into my application via REST and work out things from there.

Recently I noticed that I keep using dynamic objects as simple storage solutions like:

set settings.customerSelection = 1

instead of ending up with several variables flying around.

This certainly is way more inefficient than having simple variables but does it make a huge difference? Especially considering how much more organized the code appears?

Cheers

2
0 1583
Question praveen danda · Oct 10, 2017

Hi ,

I am newbie working on Cache .

I have a global ^BB("QA",QDJ,QTM+i) , i want to create a table or a view to access the data from this.

I am expert in creating tables & views on RDBS like Oracle, SQL server. But no idea on Cache.

Can someone guide me from scratch how to pull the data from the global.

I have installed Cache Studio on my machine.

Regards

3
0 886
Question Mack Altman · Sep 26, 2017

Recently, we scheduled two tasks (1008 and 1009) within Task Manager. Task ID 1008 is set to run after Purge Tasks (%SYS-ID:3), and Task 1009 is set to run at 7:00:00 each day.

In attempt to provide as much detail as possible, each of the tasks are as follows:

  • Task 1008WHILE (($p($h,",",2) < $ZTH("10:00 PM")) && ($P($g(^Task.1008(+$h,$j)),"^",1) = +$h)) { J ^ROUTINE, ^ROUTINE2 D SUB^ROUTINE3 H 5 }
  • Task 1009WHILE (($p($h,",",2) < $ZTH("10:00 PM")) && ($P($g(^Task.1009(+$h,$j)),"^",1) = +$h)) { d ^ROUTINE4, ^ROUTINE5 J SUB^ROUTINE6 }
4
0 935
Question Thembelani Mlalazi · Oct 10, 2017

I have an xml file that I read into objects and I am trying to print that file back in nested xml anyone with idea on how that can be achieved or where I can read in order to achieve this, here is an example of what I am trying to do.

From this

<Root>
  <FamilyMembers>
  <familyName>
  </familyName>
  <Name>
  </Name>
  <Age>
  </Age>
  <Employment>
  </Employment>
  </FamilyMembers>
</Root>

 

To this

2
0 725
Question Orion Correa · Sep 25, 2017

I have an application that as part of the registration process is using reCaptcha to provide a captcha. The issue is that service is served from Google and is unavailable in certain countries, namely China. I've been researching this some and believe it's possible to proxy the requests to the Google CDN to avoid the Chinese firewall ban on Google URLs, however I'm not quite sure how to do this in CSP. 


Does anyone have suggestions on how to solve this, either with a technical solution or an alternative service I can fall back to?
An example would be greatly appreciated.


Thanks

4
0 392
Article Alexey Maslov · Oct 9, 2017 1m read

If you have an app that uses some Caché client Windows components that are not included into CacheODBC distribution (e.g. CacheActiveX.dll), you need to proceed Caché client installation on end user's client computers and/or MS Terminal Servers. Being a part of Caché client's installation, Caché Cube is installed along with other components and is autostarted with every user's session. So, it becomes visible to every user.

To make it completely invisible, you can just move CACHE.lnk file from

"C:\ProgramData\Microsoft\Windows\Start Menu\Programs\StartUp\"
0
0 518
Article Ward De Backer · Oct 9, 2017 6m read

One of the most important features during application development is the ability to debug your code easily. Because of the asynchrnous nature, a standard Node.js application server works single-threaded by default. When you are developing applications using an IDE like Visual Studio Code, you can very easily debug your Node.js process:

First, download the free Visual Studio Code IDE (@code) and install it on your development machine.

We will start with basic debugging using a very small test.js file and go to the debug view:

0
0 2273
Question kavin kumar · Oct 7, 2017

When i tried to print .txt format,data will be coming without space between each row but when 
I tried to print .xls format mean ,it gives gap of each row.what is the reason behind this?

1
0 318
Question Ruslan K · Oct 5, 2017

How to show alert message on ZEN when user closing window?

Standart js way to add listener is not working.

I tried this

ClientMethod onloadHandler() [ Language = javascript ]{zenPage.window.addEventListener('onbeforeunload', function(e){
   
        return 'Are you sure you want to leave?';});
    
}

and this, but both are unsuccessfully .

ClientMethod onloadHandler() [ Language = javascript ]{
    
    
   zenPage.window.onbeforeunload zenPage.myClientMethod;}
5
0 818
Question Sabarinathan M · Oct 4, 2017

Hi All,

    I need some clarification on web service (Soap Service). For each Soap request, system consuming 1 license and it is not releasing until CSP session timeout and extra grace period 5.10 minutes(310 seconds).
    Due to this, at some time license consumption is full.
    If i use with Login credential (i.e password authenticated web service), it consumes one license for 25 connections(request).
    But i need to use it as anonymous user(Unauthenticated).
    Please advice.

Thanks,
Sabarinathan M

3
0 640
Question Arcady Goldmints-Orlov · Oct 3, 2017

I have a class that has a list property, which contains a list of other objects, and I want to join against it in SQL.

Class Foo Extends %Persistent
{
Property MyBars As list Of Bar;
}

Class Bar Extends %Persistent { Property Name As %String; }

Simply querying the Foo table, I see that MyBars looks like a $LIST, so I tried using a query with the %inlist operator but that didn't seem to work as expected. The following query produces zero results:

select bar.name from foo join bar on bar.id %INLIST MyBars

7
0 3123
Question Adam Skurek · Oct 3, 2017

Hello,

we have to implement some application logic using either Java or .NET. Which should we choose? Given that all other considerations are equal, which is in your experience better way performance-wise to interact with external components in Caché: .NET Gateway or Java Gateway?

Thanks.

1
0 431
Question Evgeny Shvarov · Sep 30, 2017

Hi, folks!

Is there any way to use $CASE or $SELECT functionality in SQL SELECT query?

E.g. something like this:

SELECT product, $CASE(status,"New":field1,"Payed":field2) as data from sales

To see either in data column either field1 or field2 values in regard of status value.

3
0 944
Question Jenna Makin · Sep 29, 2017

Hi-

I am running the latest version of Cache and am trying to use the Config.* classes in the %SYS namespace to be able to gather information from a cache.cpf file that was provided to me by a customer.  The customer is running an older version of Cache which had a different Version number in the cpf file.  Theirs is 2013.1 and mine is 2015.1.  

My question is, are the Config.* classes backwards compatible.  Can I use a 2017.1 version of Cache to read information from cpf file from a 2014 system?

12
0 381
Question Thomas Li · Sep 26, 2017

Hi all-

We used to have this Java applet in our CSP page to "print all" and "download all" PDF medical reports.  We want this applet so that the user won't have to open each PDF in the browser just to print it.

But now most browsers do not support Java applets anymore due to security concerns, so that Java application is down.  We tried to migrate to Java Web Start but don't know how to invoke the JNLP file from the CSP page.  I am new to Cache so any help would be greatly appreciated.

6
0 1014
Question Adam Skurek · Sep 28, 2017

Hello,

I am looking for ObjectScript implementation of crypt-compatible function, that generates md5 salted hashes (output is in the form of $1$salt$hash). From what I understand it uses its own spin on md5 algorithm:

https://en.wikipedia.org/wiki/Crypt_(C)
http://php.net/manual/en/function.crypt.php
http://www.gnu.org/software/libc/manual/html_node/crypt.html

Does Cache have something like that built in?

Has somebody here seen it implemented somewhere?

Thanks.

Added:

I have found description of the underlying algorithm here: https://www.vidarholen.net/contents/blog/?p=32

7
0 549
Question Soufiane Amroun · Sep 28, 2017

Hi , i have a JSON record as follow {value1,value2, value3}

i want to write my switch statement in this form:

<switch> my value
<case> value1</case>
<case>value2</case>
<case>value3</case>
​</switch>

is there any possibility to extract values from JSON record and put them in a  switch statement?

thank's

1
0 2500