Storing a string on disk, permanently, is just as easy as using regular variables. Just use the ^ (caret) character as the first character of the variable name. The example saves a string in the variable ^x
which is different than the regular variable x
. Even if you kill all regular variables, ^x
remains. We'll discuss this topic in detail soon.
SAMPLES>set x = 4
SAMPLES>set ^x = "Store this on disk"
Store this on disk
© 1997-2019 InterSystems Corporation, Cambridge, MA