Hi!
While i am trying to write a data i am getting a error as "<PROPERTY DOES NOT EXIST>zFile+15^User.zKQRest.1 *value,%Collection.ListOfObj" but there are values stored in it. How can i break it write it separately.
An object data model is that data or code is composed of modules that combine data and procedures that work on the data.
Hi!
While i am trying to write a data i am getting a error as "<PROPERTY DOES NOT EXIST>zFile+15^User.zKQRest.1 *value,%Collection.ListOfObj" but there are values stored in it. How can i break it write it separately.
Hi
1. Is it possible do define an index like that :
create index UIX on MyTable (Column1) where Column1 is not null
2. What happens if we add an index on a property that is NOT required, meanning that not all records will be indexed because we do not allow null subscripts ?
Hi, I am trying to understand the transformational methods.
I have created a small class with the only property of List as %List, see below.
Class LastName.Demo2 Extends %Persistent
{
Property List As %List;
}
Then I entered the following commands in the Terminal
Set Oref=##class(LastName.Demo2).%New()
FOR I=1:1:5 S $LI(List,I)="Value="_I
Set Oref.List=List
WRITE Oref.ListLogicalToDisplay(Oref.List)
^
<METHOD DOES NOT EXIST> *ListLogicalToDisplay,LastName.Demo2
zw Oref
Oref=<OBJECT REFERENCE>[2@LastName.Demo2]
The data type %Char or %Library.Char
The description says it is a fixed length character field.
How do I set the fixed length?
Or by just setting %Char to something, does that automatically define its length?
Are the parameters MINLEN, MAXLEN involved? Or are these the way I set the fixed length?
Any help with this?
In a previous exercise, I was able to show the power of Caché.
A medium-designed set of interdependent tables with some GB of data.
URLs cross reference over some million pages resulting in ~3 billion records
Competition was between
Criteria were Speed + Storage consumption
I composed a customized loader fed over a "raw" TCP connection
Mapping the "objects" into the final table by directly writing to Global Storage.,
Hi, folks!
There is an interesting discussion in the neighboring topic which raises a question for me: is there any reason to have %Status as a return value for COS method?
In reviewing the documentation found here, it states that there is an Attributes property. Since this is an array, I was wondering how I would go about traversing through the array to review what attributes are available on the file.
Hello.
I'm using device redirection to intercept incoming writes and need to figure a smart way to detect when to CLRF in order to prevent misleading outputs.
So basically, if the intercepted write ends with !, I need to know that and prevent my routine from writing ! as well.
Here's the source code for it:
Have very little XML experience and have been able to manually create output. Have a need to take data that I store in a M global (example: ^TML("HDATA", ) and out put it in CCDA XML format.
Are there any examples of M code using the XMLWriter to accomplish this?
Or can anyone provide some guidance
Any help would be greatly appreciated.
Is it possible to import a Cube from SQLServer (format .abf) in a Cache?
I have an .abf file and I want to open it in Cache. Is it possible?
Thanks
Hi, I would like to read a row out of an external SQL table and reference the returned results directly from my cache class. I've set up a link table and a SQL gateway connection. but I'm not real sure how to use them in COS. Anyone have examples out there, or some assistance? Thank you.
Hi everybody, We have written a convert from Punycode. This is reformed from javascript. Perhaps many non-English systems need to use this feature in domain name resolution. Anyone can use and change the code as needed.
Hi! I am trying to automatically populate an array property of cash amounts keyed by currency ("GBP", "USD", etc). This property needs to be NOT stored on the database and visible via SQL and the cache object.
Here's my attempt. Ultimately the array will be populated based on the the some child classes, but for now I'm just hardcoding it:
Property Amounts As array Of %Numeric [ SqlComputeCode = { set {*} = ##class(ContainerSize).GetTotalAmounts()}, SqlComputed, Transient ];Hi everyone
Is there any way to change a class definition (especifically a query definition during the compilation time)?
The idea is:
I have an abstract class with a parameter where I will define the ROWSPEC of a query and some methods to populate e temporary table
The implementation class will override the parameter, specifying the ROWSPEC of this implementation, and the methods will populate the rows in the same format as the ROWSPEC.
Hi
I have two persistent classes defined. Lets call it Parent and Child.
Child class is one of the property of Parent Class.
I would like to define a index on Child class.
So what is the default behaviour I defined a index on a non simple data type member?
Any possibility that I could customized the behaviour ? For example. Child class has three properties.
Could I configure the index to index any combinations of these three properties?
Thanks for your help.
Hi!
I have a global-mapped class that I want to add a transient property through (or at least, not stored on the database). This property is the sum total of various charge classes that are linked to the class via child relationships.
I want this new transient property to be visible at least via SQL.
Greetings, can someone give me some help? I'm trying to use job for a instance method, as it's described here but...
Anyway, I have a method like this:
Method PrepareInstance(path){set ..Tool = ##class(Tool).%New(path)do $System.Event.Signal($zparent)}That is being called like this:
Method TestPurge() As %Status{job ..PrepareInstance(..GetTestDirectory("../fixtures/_/dummy-project"))::10set msg = $System.Event.Wait("",10)
}But it fails because:
<METHOD DOES NOT EXIST>zTestPurge+1^UnitTest.Tool.1 *PrepareInstance
I am working with Caché Relationships.
I know how to iterate through the One side of the relationship and for each One iterate through all the various Manys.
What I have been trying to figure out, is the code (I can put into a Class) that will start at the top of the Manys, iterate down and for each of the Manys, pull the associated One.
I can do this with SQL or Globals, but I want to use only Class type code.
Is that clear? Any help?
You might find it useful or not. It depends on what you can imagine it to be used with, like I had to.
Either way, I created a lib that can fetch environment variables from a file or from the OS where Caché is running.
Mostly know as dotenv. Many languages have it, so why not Caché?
The usage is pretty simple:
If you want to use OS env vars exclusively, just use the method:
##class(DotEnv.Parser).FromOS()
Otherwise, if you want to specify a .env file containing your variables to complement the OS ones use the method:
##class(DotEnv.Parser).FromPath("/path/to/file")Hi, folks!
I need to get the source code of a class installed on a remote server. I have no Studio or Atelier access to it but I can manage REST and Web terminal access.
What is the easiest way for me to make it?
Quotes (1NF/2NF/3NF)ru:
Every row-and-column intersection contains exactly one value from the applicable domain (and nothing else). The same value can be atomic or non-atomic depending on the purpose of this value. For example, “4286” can be
- atomic, if its denotes “a credit card’s PIN code” (if it’s broken down or reshuffled, it is of no use any longer)
- non-atomic, if it’s just a “sequence of numbers” (the value still makes sense if broken down into several parts or reshuffled)
This article explores the standard methods of increasing the performance of SQL queries involving the following types of fields: string, date, simple list (in the $LB format), "list of <...>" and "array of <...>".
Caché offers a number of methods for going through a collection and doing something with its elements. The easiest method uses a while-loop and lets you fulfill the task in an imperative manner. The developer needs to take care of the iterator, jumping to the next element and checking if the loop is within the collection.
How do we generally create an error object of %Status?
Set status=$SYSTEM.Status.Error($$$GeneralError,"Something went wrong")
Now, like $$$GeneralError there are many more macro defined within %occErrors include file by Intersystem which we can use.
This is a translation of the following article. Thanks [@Evgeny Shvarov] for the help in translation.
This post is also available on Habrahabrru.
The post was inspired by this Habrahabr article: Interval-associative arrayru→en.
Since the original implementation relies on Python slices, the Caché public may find the following article useful: Everything you wanted to know about slicesru→en.
Note: Please note that the exact functional equivalent of Python slices has never been implemented in Caché, since this functionality has never been required.And, of course, some theory: Interval treeru→en.
All right, let’s cut to the chase and take a look at some examples.
Hi,
We have a method written in cache studio that converts XML file to JSON and JSON file to XML, Can we use this method in ensemble production.
It is possible to update Cache object property from Python using the following Python code, with import of intersys.pythonbind3:
my_object.set("my_property",["A","B","C"])
However, I am unable to save 2D %List with 2D Python array like the following:
my_object.set("my_property",[["A","B","C"],["1","2","3"]])
I am not sure whether this is Python-Cache bind flaw or design issue. Is there any alternative/ workaround to do the same for above?
Hi, Community!
And so I continue with publishing of the tasks for the Final round of InterSystems Contest on InterSystems Caché and DeepSee as a part of IT Planet Student Championship in Sochi. This year we had about 2 000 participants in InterSystems Contest.
One of the tasks for the finals was to crack the black box!
Hi all,
I have a non objectscript application connecting to a cache instance via ODBC and one column is a list of serial objects. The output from the query contains a lot of special characters and I'm hoping there's a better way to get this data back so I won't have to perform extensive parsing on the application side.
I've tried using the $ListToString() function, but that didn't help much, probably because the list contains complex objects rather than primitives.
Any help will be greatly appreciated!
How can i compare two files using cache program, i need this for unit testing purpose