Hi All,
How to update an attribute value of an object without changing r_modify_date and r_modifier?
--Arun
If there are Accepted Answers, those will be shown by default. You can switch to 'All Replies' by selecting the tab below.
Hello Arun,
the first query won't work since custom attribute is not part of dm_sysobject so dm_sysobject_s table does not have cust_attr.
in secind query, i noticed that you have specified update query in double quotes, it should be under single quotes (and for any occurenence of single quote use two single quotes) and should refer table name and not object name like:
EXECUTE exec_sql WITH query= 'update cus_object_s set cus_attr =''testing value'' where r_object_id=''object_id''';
please try this and let me know if this works.
At the database w SQL… But that goes against the fundamental security and design of Documentum. R_ attributes are “Reserved” and not meant to be altered directly as such.
You can do so via using following DQL:
EXECUTE exec_sql WITH query='sql_query'
any attribute update via above DQL will not update r_modify_date and r_modifier
Hi Kyle,
Thanks for your update, I don't want to update the r_attributes of object. I have a custom object "cus_object" for that I have created custom attribute "cus_attr". My requirement is to change the value of "cus_attr" only without changing values of r_modifier and r_modify_date.
Hi tejrajs,
Thanks for the update. I have already tried with EXECUTE exec_sql WITH query='sql_query' but I could not able to achieve.
The following are my query failed while executing. Please verify it and understanding my requirement provide the correct query.
1.EXECUTE exec_sql WITH query="update dm_sysobject_s set cus_attr ='testing value' where r_object_id='object_id';
2.EXECUTE exec_sql WITH query="update cus_object set cus_attr ='testing value' where r_object_id='object_id';
Thanks its working.
Hi Tejrajs,
I got a situation here. The above methods are working for the own attributes of the objects. And if we do for inherited attributes that is attributes from the super type objects.
For eg:
main_obj is the super type object
cus_object is child object of main_obj
main_obj have attribute called main_attr and that is inherited in cus_object. Now I have to update value of the main_attr of the cus_object type.
If i used the same above methods I am getting error like attribute not found.
Help me
You cant update the parent attribute in child object by SQL.
EXECUTE exec_sql WITH query= 'update main_obj set main_attr =''testing value'' where r_object_id=''object_id''';
You should also increment the i_vstamp in the same transaction so that if the object is cached anywhere, the change that you made would be realized.
-Matt