AnsweredAssumed Answered

Integrity Check problem when adding a node?

Question asked by blatwurst on Oct 24, 2007
Latest reply on Oct 24, 2007 by blatwurst
Can someone please help me understand what's going on here?  Why does this:

        obj = obj.createNode("app:configurations", "app:configurations", "app:configurations");
produce this error:

Invalid property value: 
   Node: workspace://SpacesStore/c3764e1f-8235-11dc-b853-a9503a1a1ee3
   Type: {}configurations
   Property: {}name
   Constraint: Value 'app:configurations' matches regular expression: (.*[\"\*\\\>\<\?\/\:\|]+.*)|(.*[\.]?.*[\.]+$)|(.*[ ]+$)

It's complaining about the ':' in the name of the association (the first parameter to createNode).  I tried this too, with the same result:

        var props = new Array();
        props["cm:name"] = "blah blah blah";
        obj = obj.createNode("app:configurations", "app:configurations", props, "app:configurations");

This code succeeds:

        obj = obj.createNode("configurations", "app:configurations", "app:configurations");

but then the name of the resulting association is "cm:configurations" rather than "app:configurations".  The fact that this works says to me that what I'm trying to do should work.  That is, the value I'm providing should be able to be qualified with a namespace since the default namespace is added to the value I provide if I don't specify one explicitly.

Do I have to turn off integrity checks to make this node? That seems harsh.  BTW, I'm trying to reproduce the same node relationship that exists below each "person" node.

Any help would be appreciated.