In Documentum, data is stored in various object types, with dm_document
being one of the most frequently used. To effectively interact with this object type, Documentum provides different views, each serving a specific purpose. These views are designed to handle both single-valued (non-repeating) and repeating attributes, and they are accessed by different components of the Documentum system.
In this blog, we’ll break down the four main views associated with dm_document
: dm_document_sp
, dm_document_sv
, dm_document_rp
, and dm_document_rv
. Understanding these views is key for developers and administrators who need to interact with Documentum through DQL or Object Manager.
The Four Views of dm_document
dm_document_sp
– Single-Valued Attributes for DQLdm_document_sv
– Single-Valued Attributes for Object Managerdm_document_rp
– Repeating Attributes for DQLdm_document_rv
– Repeating Attributes for Object Manager
1. dm_document_sp
: Single-Valued Attributes for DQL
The _sp
(Single-valued for DQL) view is used by DQL (Documentum Query Language) to interact with non-repeating attributes of the dm_document
type. Non-repeating attributes are those that can hold only one value. For example, attributes like object_name
(the document name) or r_object_id
(the document ID) are non-repeating and accessed through this view.
When you execute a DQL query to retrieve non-repeating attributes, Documentum refers to the _sp
view to extract the data. This view ensures that DQL queries for these attributes are optimized and properly handled by the system.
2. dm_document_sv
: Single-Valued Attributes for Object Manager
The _sv
(Single-valued for Object Manager) view serves the Object Manager, Documentum’s internal component responsible for managing objects within the repository. Similar to the _sp
view, _sv
is used for non-repeating attributes, but it is specifically utilized by the Object Manager to fetch or update these attributes when interacting with dm_document
objects.
For developers working with Documentum’s internal systems or through administrative interfaces, the _sv
view is the underlying table where single-valued attributes are processed for object management operations.
3. dm_document_rp
: Repeating Attributes for DQL
The _rp
(Repeating for DQL) view is used to manage repeating attributes when executing DQL queries. Repeating attributes are those that can hold multiple values. For example, the keywords
attribute in dm_document
can have several values assigned to it. If you run a DQL query to retrieve these repeating attributes, Documentum will utilize the _rp
view to handle them.
DQL is capable of working with both single-valued and repeating attributes, and this separation into _sp
for single-valued and _rp
for repeating attributes allows for efficient data handling in the repository.
4. dm_document_rv
: Repeating Attributes for Object Manager
The _rv
(Repeating for Object Manager) view is similar to _rp
, but it is designed for the Object Manager to manage repeating attributes. When the Object Manager interacts with dm_document
and encounters repeating attributes like keywords
, it references this _rv
view to properly manage and update these multi-valued fields.
This distinction between repeating and non-repeating attributes helps ensure that both DQL queries and the Object Manager can handle document data efficiently, no matter how many values an attribute contains.
Key Differences Between DQL and Object Manager Views
The primary difference between the _sp
, _rp
views and the _sv
, _rv
views lies in who uses them:
- The
_sp
and_rp
views are used by DQL when you are querying or manipulating data with DQL commands. - The
_sv
and_rv
views are used by the Object Manager, an internal component that handles object operations behind the scenes.
Furthermore:
_sp
and_sv
handle single-valued (non-repeating) attributes._rp
and_rv
handle repeating attributes.
Practical Example: Querying Non-Repeating and Repeating Attributes
Let’s look at an example where you want to query both non-repeating and repeating attributes of a dm_document
.
Querying Non-Repeating Attributes
To retrieve non-repeating attributes like the document name and creation date, you would write a DQL query that accesses the _sp
view behind the scenes:
SELECT object_name, r_creation_date
FROM dm_document
WHERE r_object_id = '090000028000abcd';
This query will use the dm_document_sp
view to fetch these single-valued attributes.
Querying Repeating Attributes
If you need to retrieve a repeating attribute like keywords
, you would use a query that relies on the dm_document_rp
view:
SELECT keywords
FROM dm_document
WHERE r_object_id = '090000028000abcd';
In this case, the query will pull data from the _rp
view, ensuring that all values in the repeating attribute are returned.
Conclusion
Understanding the distinction between dm_document_sp
, dm_document_sv
, dm_document_rp
, and dm_document_rv
views is crucial for working effectively in Documentum. Whether you’re writing DQL queries or interacting with the system through the Object Manager, knowing which views handle single-valued versus repeating attributes allows you to optimize data retrieval and manipulation.
By using the appropriate views, Documentum ensures efficient access to both types of data and maintains system performance even as document repositories grow. Whether you are an administrator or a developer, these views play an important role in how you interact with and manage content in Documentum.