Data Model

Syndicate content 13 

Hi guys!

As you know there are two (at least) ways to get the stored value of the property of InterSystems IRIS class if you know the ID of an instance (or a record).

1. Get it by as a property of an instance with "Object access":

ClassMethod GetPropertyForID(stId As %Integer) As %String

{

set obj=..%OpenId(stId)

return obj.StringData

}

2. Get it as a value of a column of the record with "SQL access":

Last answer 29 June 2019 Last comment 9 days ago
0   0 4
107

views

0

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
626

views

+ 6

rating

Dear Colleagues and Friends,

is there any indication that the .NET object representation of Cache objects (i.e. InterSystems.Data.CacheClient.dll) complies with .NET Standard? I'm planning to extend our existing .NET client/server solution with a mobile option by Xamarin Forms and can't find any significant hints in the internet.

I'm just fooling around a bit and made some expreiments with a REST API and a generic object-to-JSON tier:

Last comment 1 April 2019
0   0 2
0

answers

83

views

0

rating

How Tax Service, OpenStreetMap, and InterSystems IRIS
could help developers get clean addresses

 

Pieter Brueghel the Younger, Paying the Tax (The Tax Collector), 1640

 

In my previous article, we just skimmed the surface of objects. Let's continue our reconnaissance. Today's topic is a tough one. It's not quite BIG DATA, but it's still the data not easy to work with: we're talking about fairly large amounts of data. It won't all fit into RAM at once, and some of it won't even fit on the drive (not due to lack of space, but because there's a lot of junk). The name of our subject is FIAS DB: the Federal Information Address System database - the databases of addresses in Russia. The archive is 5.5 GB. And it's a compressed XML file. After extraction, it will be a full 53 GB (set aside 110 GB for extraction). And when you start to parse and convert it, that 110 GB won't be enough. There won't be enough RAM either.

+ 2   2 1
0

comments

149

views

+ 2

rating

First time post, also a new Cache developer, hence the <Beginner> tag.

If our data has Predefined terms in a dictionary, and a user can add terms on their own, can the terms exist in different tables?

Lets call the tables "Terms" and the user data in "UserTerms".

If a third class definition has a property of "Term" can it not be either Terms or UserTerms?

I'm leaning towards using a Subclass strategy where the pseudo "Parent" (forgive me) is  Dictionary.Term and the child is along the lines of Dictionary.Term.User

Last answer 26 March 2019 Last comment 28 March 2019
0   0 3
96

views

0

rating

Just wondering an Insight in the difference between these two indexes

IdKey / PrimaryKey
================= 

Property Identifier As %Integer

Index Index1 on Identifier [Idkey]

Index Index2 on Identifier [PrimaryKey]

What's the difference?

1. If I don't have Index1 and only have Index2,  then cache does still make its own id.
So how and why  do I ever use the PrimaryKey.  In Joins ??

Last answer 5 March 2019 Last comment 6 March 2019
+ 1   0 6
211

views

+ 1

rating

Let's say I have a property as a variable value:

set propName="Country"

Is there a method to determine, should I quote it to access the object, so would the correct code be:

write obj."Country"

or just simple

write obj.Country

is enough?

Last answer 24 January 2019 Last comment 25 January 2019
0   0 3
126

views

0

rating

Headache-free stored objects: a simple example of working with InterSystems Caché objects in ObjectScript and Python

Neuschwanstein Castle

Tabular data storages based on what is formally known as the relational data model will be celebrating their 50th anniversary in June 2020. Here is an official document – that very famous article.  Many thanks for it to Doctor Edgar Frank Codd. By the way, the relational data model is on the list of the most important global innovations of the past 100 years published by Forbes.

On the other hand, oddly enough, Codd viewed relational databases and SQL as a distorted implementation of his theory.  For general guidance, he created 12 rules that any relational database management system must comply with (there are actually 13 rules). Honestly speaking, there is zero DBMS's on the market that observes at least Rule 0. Therefore, no one can call their DBMS 100% relational :) If you know any exceptions, please let me know.

+ 4   3 1
0

comments

294

views

+ 4

rating

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?

Last answer 14 November 2018 Last comment 14 November 2018
+ 1   0 2
292

views

+ 1

rating

Hi,

I would like to know if anyone has had some experience in building systems for multiple end-users. 

To keep things simple, in a hypothetical example, say an Event Booking System, where a Venue could sign up to use such a system and define it's Venue, costs, calendars, etc.. and then invite their customers to book the Venue on different days/times. 

If I wish to offer such a system to many Venues, there are a number of options available.

Last answer 25 October 2018 Last comment 26 October 2018
0   0 5
335

views

0

rating

We have a case where a vendor can send us more information in the DICOM message rather than in the HL7 result message. In theory it should be possible to take a DICOM and convert it to HL7, stupid question is has anyone done it before? Does anyone have any good examples of a DTL they did to show me how to setup the message structures and translation?

Thanks

Scott Roth

The Ohio State University Wexner Medical Center

Scott.Roth@osumc.edu

Last answer 14 March 2018 Last comment 14 March 2018
0   0 2
311

views

0

rating

Connected Data London Conference

TRIADB is an emerging unique and valuable technology in NoSQL database modelling and BI analytics. The following video is from a presentation and demonstration of TRIADB prototype implemented on top of Intersystems Cache database and driven with a CLI in Python (Jupyter-Pandas). In fact this is the second time in the past year that a prototype based on this technology is implemented and demonstrated. The first one was built on top of OrientDB multi-model database and driven by a Mathematica notebook.

+ 3   0 3
0

comments

417

views

+ 3

rating

Hi, Community! 

Please welcome a new session recording from Global Summit 2017:

Building Effective Analytic Data Models

 

0   0 1
0

comments

91

views

0

rating

Beginning - see Part 1.

 

3. Variants of structures when using globals

 

A structure, such as an ordered tree, has various special cases. Let's take a look at those that have practical value for working with globals.

 

 

 

 

3.1 Special case 1. One node without branches

 

Last comment 8 July 2017
+ 6   0 5
822

views

+ 6

rating

Hi, Community!

Suppose I have class A with properties P1 and P2.

I want to introduce class B, which would have same records as Class A, but only  one property - P2.

What is the easiest  way to manage it assuming that I would like to use Class A to add records and be available for any operations to Users with Role A.

And I would like to introduce class B for Users with role B for read-only access.  Preferably they shouldn't even be aware of Class A and P1 existence .

What is the easiest way to introduce it and manage it?

Last answer 9 June 2017 Last comment 10 June 2017
0   0 3
362

views

0

rating

Hi

I have an Ensemble Application with many classes and relationships between those classes.

I need a tool that can connect to Cache/Ensemble and create a visual ERD from the class definitions within a particular Cache Namespace

MS-Access is one option but it does not automatically create the relationship connectors between classes

Any suggestions

Nigel Salm

Last answer 3 May 2017 Last comment 5 May 2017
0   0 7
1919

views

0

rating

In the prior part of this series we have provided introduction to Google MapReduce approach, but still not covered their possible ObjectScript implementation. Which we will start to explain today.

Last comment 28 March 2017
+ 3   0 4
345

views

+ 3

rating

In part I of this series we have introduced MapReduce as a generic concept, and in part II we started to approach Caché ObjectScript implementation via introducing abstract interfaces. Now we will try to provide more concrete examples of applications using MapReduce.

Last comment 28 March 2017
+ 4   0 4
599

views

+ 4

rating

I've been building up a REST services API, consisting of a dozen or so classes referenced from a Dispatch class, which has route mappings for the first piece of the URI.  I'd like to have the Dispatch class be able to output all of the available Services, with some documentation.  Is there something like a %Library resource that I could use to pull this information from each of the classes?

Thanks

Chris

Last answer 17 March 2017 Last comment 9 June 2016
0   0 0
447

views

0

rating

I have been following the online Zen Quickstart Tutorial using the lastest release documentation. In addition to playing around with the styling and making a few minor functionality tweaks, I wanted to add an additional column that shows a count of the number of phone numbers for that Contact (as shown in the image below).

Last answer 28 February 2017 Last comment 15 March 2017
0   0 1
219

views

0

rating

This post is the direct result of working with an InterSystems customer who came to me with the following problem:

SELECT COUNT(*) FROM MyCustomTable

Takes 0.005 seconds, total 2300 rows.  However:

Last comment 1 November 2016
+ 10   0 11
983

views

+ 10

rating

Process-private Globals  can be used as a data global in storage definition. That way, each process can have its own objects for the class with ppg storage. For example lets define a pool, which can:

  • add elements to a pool (ignoring duplicates)
  • check if an element exists in the pool

Here's the class:

Last comment 16 August 2016
+ 4   0 3
409

views

+ 4

rating

Does anybody know how can I get the DocumentId property from a DocDM repository using SQL?. So far my SQL is like this:

SELECT name,email,gender FROM JSON_TABLE(
  'person',
  '$' COLUMNS(
    name VARCHAR(100) PATH '$.name',
    email VARCHAR(100) PATH '$.email',
    gender VARCHAR(2) PATH '$.gender'
  )

Thanks!

Last answer 8 July 2016 Last comment 8 July 2016
0   0 1
173

views

0

rating