Removes the indication that the specified record is a duplicate of another record.
This method breaks the linkage between a duplicate and original Entity object. You can call this method to break a link that was established by the user or by calling the MarkEntityAsDuplicate method. If the DUPLICATE action being undone caused a state transition, that transition is undone unless a subsequent state transition occurred after the DUPLICATE action. After this method returns, the record is editable and must be validated and committed using the Entity object's Validate and Commit methods, respectively.
VBScript
session.UnmarkEntityAsDuplicate duplicate, action_name
Perl
$session->UnmarkEntityAsDuplicate(duplicate, action_name);
VBScript
set sessionObj = GetSession ' Remove the duplicate status of the entity with ID="BUGID00010345". ' Use the action named "unduplicate". set oldDupEntityObj = sessionObj.GetEntity("defect", "BUGID00010345") sessionObj.UnmarkEntityAsDuplicate oldDupEntityObj, "unduplicate" ' Validate and commit the entity since it is currently modifiable. error = oldDupEntityObj.Validate if error = "" then oldDupEntityObj.Commit End If
Perl
#Get a Rational ClearQuest session
$sessionObj = $entity->GetSession();
#Get the entity BUGID00010345
$oldDupEntityObj = $sessionObj->GetEntity( "defect", "BUGID00010345" );
#Remove the duplicate status of the entity with #ID="BUGID00010345"
#using the action "unduplicate"
$sessionObj->UnmarkEntityAsDuplicate( $oldDupEntityObj, "unduplicate" );
#Validate and commit the entity since it is currently modifiable.
$error = $oldDupEntityObj->Validate();
if ( $error eq "" ) {
$oldDupEntityObj->Commit();
}