Before getting into details of Property Bags lets quickly see what are Qualifiable and Non-Qualifiable properties?
Most of the Object attributes are Qualifiable properties. The properties are qualifiable if it is saved (persisted) in a column of that Objects underlying tables (_r or _s table) in the Database. Attributes are Qualifiable by default. I am not getting into much detail of Qualifiable properties here. See the following link for more on this
Non – Qualifiable Properties
These Attributes of objects does not have column of its own in the Object’s underlying _r or s tables. They are saved in the serialized format in the i_property_bag property of the underlying object. See the below noted bullet points that reveal some interesting facts about Non – Qualifiable attributes.
· Though these properties can be returned using a DQL Query, this cannot be used in the Qualifying clause [in Where Clause of the Query]. The Exception to this rule is that Non-Qualifiable properties can be used in the where clause of FTQL queries
· These properties can be full text indexed.
· IF the Non-Qualifiable properties are part of the select part of the Query, the query should have r_object_id in the select list.
· If a property is Non-Qualifiable and it is of type String the length of that attribute must be less than the value of max_nqa_string key in the server.ini (Only if this key has a value set in server.ini) (The default value is 2000)
Lets See Few Related DQL’s
The following DQL creates an object type mycustomtype with first name a Qualifiable Attribute and country a Single Non-Qualifiable attribute and phone a Non Qualifiable Repating attribute.
CREATE TYPE “mycustomtype” (“firstname” string(64), country string(64) NOT QUALIFIABLE, phone string(10) REPEATING NOT QUALIFIABLE ) WITH SUPERTYPE “dm_document”
The following Query will create an object of type mycustomtype (You may notice that there is no difference in the create Query when compared with Qualifiable Properties
CREATE mycustomype OBJECT SET “firstname” = ‘Hello World’, SET “country”= ‘US’, SET phone = ‘1111111111’
The following Query will return the Attributes from mycustomtype.
Note: Make sure that you have r_object_id in the select query if you have non-Qualifiable attributes otherwise you will get following error DM_QUERY2_E_MISSING_OBJECTID_IN_SELECT_LIST
Select r_object_id, firstname, country from mycustomype;
What is Property Bag
Property bag is a relatively new term in Documentum. This is a property, which is used to store other properties and values of an Object. Non Qualifiable properties and its values of an Object is stored in its property bag (both Single and Repeated)
Other than Non-Qualifiable properties Property bag can also hold Properties and values of Aspect if the aspect properties are enabled with OPTIMIZEFETCH.
i_property_bag and r_property_bag
The i_property_bag property is defined in dm_sysobject , This Attribute is of datatype String and can hold up to 2000 characters. This makes sure that all the object types that are inheriting from dm_sysobject have the ability to have its own property bag.
In the scenarios where you don’t have a Parent type defined in the Object definition and you create a non-Qualifiable attribute this property is automatically added to the object type.
If you add property bag to an object type it can never be removed from that object type.
The r_property_bag is silently added to the Object’s type definition when we add i_property_bag. This repeating attribute property is used to store the overflow from the i_property_bag. That means if the names and values of properties stored in i_property_bag exceed 2000 chars, the overflow is stored in r_property_bag. This is repeating string property with 2000 characters.