Globals

Syndicate content 11 

Hi all, 

I am trying to create a method to count the number of entries in a global, including all subscripts. I am having a bit of trouble getting the code to make it to the second subscript. When I get to the position where my key is "Canada" and I add a comma and empty quotes to it, it returns USA as the new key when I do the order function. Is the $Order or the global not able to use a single string to represent multiple subscripts?

 

Here is my global structure:

Last answer 22 hours 41 min ago Last comment 2 days ago
+ 1   0 6
69

views

+ 1

rating

Hi Community!

Enjoy watching  the new video on InterSystems Developers YouTube, recorded by @Joel Solon, InterSystems Senior Technical Trainer:

Globals Quickstart

 

+ 1   0 1
0

comments

15

views

+ 1

rating

Hi Developers!

InterSystems IRIS stores everything in globals and if we use ObjectScript classes to persist data class documents globals it uses in storage. But if you use globals for calculations, temporary storages, for special indexes or for some other purposes - how do you document it?

Possible options which come to my mind:

1. Macro

#define Array ^MyGlobal

usage:

s $$$Array(1)=1

2. Class parameter

Parameter Array ="^MyGlobal";

Usage:

Last answer 5 days ago Last comment 7 days ago
0   0 3
132

views

0

rating

An exciting position has arisen for a Junior Application Support Analyst in an established support team at CDS Computer Design Systems Ltd  CDS is an independent SME, based near Manchester City Centre, specialising in the Oil and Gas distribution software market for over 45 years with strong ties throughout the industry https:

0   0 1
0

comments

70

views

0

rating

An exciting position has arisen for an Application Support Analyst 3rd Line, in an established support team at CDS Computer Design Systems Ltd.  CDS is an independent SME, based near Manchester City Centre (United Kingdom) specialising in the Oil and Gas distribution software market for over 45 years with strong ties throughout the industry - https://www.codas.com

0   0 1
0

comments

97

views

0

rating

I need to copy a bunch of globals from some crufty old databases to spanking clean brand new ones. GBLOCKCOPY has this cool feature that lets you create a batch of global names to copy and save the list in a batch. You can then execute the batch and go take a nap.

I like naps.

I need to do this for a number of old-new database pairs, but it's the same global names every time. Is there a way to export the batch configuration created the first time and import it to another environment/namespace? These databases will be spread across multiple hosts.

Thanks!

Last answer 18 July 2019 Last comment 18 July 2019
0   0 1
48

views

0

rating

When I start talking about InterSystems IRIS with more technically-minded people I always talk about how at the root of things it is a multimodel DBMS.

In my opinion that is the main advantage (on the DBMS side).

You want some sort of summary for your data? Use SQL!

Do you want to work extensively with one record? Use objects!

Want to access or set one value and you know the key? Think again. Use globals!

And the data is stored only once. You just choose the way you want to access it.

On the first overview it's a nice story - short and concise and it gets the message across, but when people really start working with InterSystems IRIS the questions start.

How are classes and tables and globals related? What are they to each other? How's data really stored?

In this article I would try to answer these questions and explain what's really going on.

+ 5   1 1
0

comments

190

views

+ 5

rating

Hi Community!

Please welcome a new video on InterSystems YouTube Channel:

InterSystems and Python QuickStart

 

+ 1   1 1
0

comments

129

views

+ 1

rating

In the previous parts (1, 2) we talked about globals as trees. In this article, we will look at them as sparse arrays.

A sparse array - is a type of array where most values assume an identical value.

In practice, you will often see sparse arrays so huge that there is no point in occupying memory with identical elements. Therefore, it makes sense to organize sparse arrays in such a way that memory is not wasted on storing duplicate values.

In some programming languages, sparse arrays are part of the language - for example, in J, MATLAB. In other languages, there are special libraries that let you use them. For C++, those would be Eigen and the like.

Globals are good candidates for implementing sparse arrays for the following reasons:

Last comment 23 May 2019
+ 6   0 5
650

views

+ 6

rating

Suppose we need to store millions of values temporarily, that means, we don't care about them if we lose them but our application use them to get realtime information. Should I use Cachetemp or whatever other DB without journaling enabled? If answer is Cachetemp, shouldn't be a problem if we decide to scale using App Server + ECP? I'm not sure what would happen with the app logic in such architecture as I guess I couldn't map and share cachetemp...

Any idea/suggestion?

Last answer 13 February 2019 Last comment 13 February 2019
0   0 3
135

views

0

rating

Hi,

Most of my classes are mapped from Globals. I want to access Cache classes from a BI software through ODBC connection.

'Last update' information does not exist in most of the classes. My question is whether there is a 'last update' timestamp that is automatically generated for each line in classes I can extract to external systems?

Thanks

Last answer 10 November 2018 Last comment 12 November 2018
0   0 2
284

views

0

rating

It's well-known that namespace global mapping helps us to write code independent on database storage details (Caché instance name, directory path). But sometimes we can face problems accessing an unsubscripted global which has subscript level mapping (SLM) defined. Most of such cases are evident and associated with administrative tasks that should be done on database level, but some of them can confuse even an experienced developer. Just to start:

Last comment 13 October 2018
+ 4   0 3
635

views

+ 4

rating

Hi,

I've read into console.log that there is some problems writing the global Task History

09/13/18-09:33:00:109 (9052) 0 Error al escribir en global de historial de tareas - Error (ERROR #5002: Error de cache: <DATABASE>%SaveData+20^%SYS.Task.History.1 ^SYS("Task","HistoryD",66179),c:\intersystems\healthshare\mgr\)

Last answer 14 September 2018 Last comment 14 September 2018
0   0 1
99

views

0

rating

I am still working on a generic task where I need to apply journal file records to another database. Initially I didn't want to use Journal.Restore class methods as I need to perform some data transformation, and it seemed that the clearest way to achieve it was to read journal file record by record using %SYS.Journal.Record API. 

Last answer 16 June 2018 Last comment 16 June 2018
+ 1   0 2
155

views

+ 1

rating

The Art of Mapping Globals to Classes (4 of 3)

The forth in the trilogy, anyone a Hitchhikers Guide to the Galaxy fan?

If you are looking to breathe new life into an old MUMPS application follow these steps to map your globals to classes and expose all that beautiful data to Objects and SQL.

If the above does not sound familiar to you please start at the beginning with the following:

The Art of Mapping Globals to Classes (1 of 3)

Last comment 12 June 2018
+ 5   0 6
905

views

+ 5

rating

I'm working on a task where I need to apply journal file records to another database. I can't use Journal.Restore class methods as I need to perform some data transformation, therefore I'm reading journal file record by record using %SYS.Journal.Record API.  

It seems that there are only few journal records that I need to process, namely:

Last answer 7 June 2018 Last comment 7 June 2018
0   0 3
180

views

0

rating

Hi,

I wonder if you could help me with a problem with persistent globals and journals.

We have a few interfaces using a persistent global just to translate some codes. The use of that global is like a lookup table...an interface calls a method that search for a field (in the message) in the global. If found, the code is translated with another field from the global.

The format of the global is something like:

Last answer 10 May 2018 Last comment 11 May 2018
0   0 2
244

views

0

rating

Hi! I have a local project written on Cache and Atelier on my PC. I need to move it to notebook. Tried to export globals, classes, MAC-programms and csp with frontend stuff, but after I created my apps on notebook and imported my set, it just didn't work. I think it's because I have some settings on Management Portal, so how can I export portal settings and what I should export to have my working apps on another computer?

Last answer 29 April 2018 Last comment 29 April 2018
0   0 2
136

views

0

rating

Hi.

The message is received a few times a day.

On documentation, this ^ISCSOAP^is log to service SOAP, but why send to cconsole.log?

04/04/18-01:00:00:597 (10608) 2 ^ISCSOAP in Namespace %SYS has been active for 348 day(s).
04/04/18-01:00:00:598 (10608) 2 ^ISCSOAP in Namespace X has been active for 165 day(s).

Help-me.

Tks

Last answer 5 April 2018 Last comment 5 April 2018
0   0 5
314

views

0

rating

I have a simple app which tries to establish a connection with a Cache database instance via Global API for Java:

import com.intersys.globals.Connection;
import com.intersys.globals.ConnectionContext;

public class Assignment {

    public static void main(String[] args) {
        Connection connection = ConnectionContext.getConnection();
        connection.connect("SAMPLES", "_SYSTEM", "SYS");
    }

}

The expection I am getting:

Last answer 27 February 2018 Last comment 25 March 2018
0   0 4
456

views

0

rating

Is there something in Cache that is equivalent to partitioning a table in Oracle? I'm trying to break some big tables into groups so that the most frequently accessed data is faster to retrieve.

Here is some information on this concept from Oracle.

https://docs.oracle.com/cd/B28359_01/server.111/b32024/partition.htm

Last answer 28 April 2016 Last comment 23 March 2018
+ 3   0 1
503

views

+ 3

rating

Is there a way to pull a user name and password from the Credentials list that is kept in Ensemble? Right now I have a LDAP user that I have hard coded into my ZAUTHENTICATE, which I would like to get away from. I am not to familiar with settings Global, or calling them at least.

Thanks

Scott

Last answer 24 February 2018 Last comment 1 March 2018
+ 1   0 5
618

views

+ 1

rating

Hi Guys,

I would like to know, how to setup a global structure in Cache classes storage type.

I want to set a global like below in Cache classes using Storage methods.

^A("ID1")="Name\Abb\Map"

^A("ID2")="Name\Abb\Map"

^A("ID3")="Name\Abb\Map"

...

If any lead it would be appreciated. 

Thanks,

Arun Kumar Durairaj.

Last answer 1 February 2018
0   0 2
0

comments

179

views

0

rating