Skip to main content

This is documentation for Caché & Ensemble.

For information on converting to InterSystems IRISOpens in a new window, see the InterSystems IRIS Migration Guide and Migrating to InterSystems IRIS, both available on the WRC Distributions pageOpens in a new window (login required).

Storing Data on Disk

Storing something on disk, permanently, is just as easy as using regular variables. Just place the ^ (caret) character in front of the variable name. The example saves a string in the variable ^x which is different than the regular variable x. We'll discuss this topic in detail soon.

This example will display the current value of ^x before updating it, each time you run it.

x = 4
println "x = ", x
println "old value of ^x = ", ^x
^x = "random number: " & int((rnd()*10))
println "new value of ^x = ", ^x
Copy code to clipboard
FeedbackOpens in a new window