Caché Objects

Subscribe to Caché Objects content with RSS Syndicate content or email

Logging using macros in InterSystems Caché

In my previous article, we reviewed possible use-cases for macros, so let’s now proceed to a more comprehensive example of macros usability. In this article we will design and build a logging system.

Logging system

Logging system is a useful tool for monitoring the work of an application that saves a lot of time during debugging and monitoring. Our system would consist of two parts:

  • Storage class (for log records)
  • Set of macros that automatically add a new record to the log

views

rating

Can you create ad-hoc Caché relationship objects?

Can you create ad-hoc Caché relationship objects that are not part of the original Caché class definition?

views

rating

Converting objects between classes

Let's say I have two classes: A and B. They share no common parent except %SystemBase. But these classes have some properties with the same name (type may be the same or not):

views

rating

String Datatype with regular expression validation

Hi folks,

I've created a datatype class whoch extends from %Library.String with a REGEX parameter and the validation of the value against the regular expression. The class does not support Populate using the regular expression as a template for data population.

views

rating

Making encrypted datafields SQL-searchable

Overview

Encryption of sensitive data becomes more and more important for applications. For example patient names, SSN, address-data or credit card-numbers etc..

Cache supports different flavors of encryption. Block-level database encryption and data-element encryption. The block-level database encryption protects an entire database.  The decryption/encryption is done when a block is written/read to or from the database and has very little impact on the performance.

With data-element encryption only certain data-fields are encrypted.  Fields that contain sensitive data like patient data or credit-card numbers. Data-element encryption is also useful if a re-encryption is required periodically. With data-element encryption it is the responsibility of the application to encrypt/decrypt the data.

Both encryption methods leverage the managed key encryption infrastructure of Caché.

The following article describes a sample use-case where data-element encryption is used to encrypt person data.  

But what if you have hundreds of thousands of records with an encrypted datafield and you have the need to search that field? Decryption of the field-values prior to the search is not an option. What about indices?

This article describes a possible solution and develops step-by-step a small example how you can use SQL and indices to search encrypted fields. 

views

rating

views

rating

Getting my head around a class model

There's plenty of goodness in the %-packages InterSystems supplies, and it seems that every new version of Caché brings something new. The browser-based class documentation (a.k.a.

views

rating

Fastest way to strip invalid characters from stream

A method to convert certain non-readable ASCII characters in a %Stream.FileCharacter object first copies it into a

views

rating

Error fuction

How to know the severity, priority, urgency of error in intersystem cache

views

rating

Object Saving Taking More Time

Hi,

I am saving 2000 objects of a class in a loop.

In one environment it is taking a total of 86 seconds and in another environment it is taking 0.55 seconds.

views

rating

Trusting the code you import

As more people join Developer Community, and with increasing efforts to promote code sharing, I'd like to draw fresh attention to

views

rating

How to add the case insensitive index to a class?

Hi!

Consider I have a class Package.Data with Property UniqueStringValue as %String.

I introduced the Index for this property:

views

rating

Parse %ObjectIdentity

Hi!

I'm trying to implement %OnAfterDelete ClassMethod for persistent class. As a parameter it gets oid As %ObjectIdentity for the deleted object.

views

rating

How to Export Data to Excel in Cache Object.

Please Give a simple program for how to export data to Xls format in Cache Objects.

views

rating