We often came accross a situation where we need to modify some property value for multiple objects. To expedite this process we do it through job. I also found a similar case. In my situation i was required to update 'Modified by' field of the table to yes so that each table will record the information of which user has modified the record. Here is the simple job for this
TreeNode TreeNode;
TreeNode BaseTreeNode;
UtilEntryLevel UtilEntryLevel;
#AOT
;
BaseTreeNode = TreeNode::findNode(#Tables Path);
TreeNode = BaseTreeNode.AOTfirstChild ();
while(TreeNode)
{
treeNode.AOTsetProperty("M odifiedBy", "Yes");
TreeNode.AOTcompile();
TreeNode.AOTsave();
TreeNode=TreeNode.AOTnextS ibling();
pause;
}
TreeNode TreeNode;
TreeNode BaseTreeNode;
UtilEntryLevel UtilEntryLevel;
#AOT
;
BaseTreeNode = TreeNode::findNode(#Tables
TreeNode = BaseTreeNode.AOTfirstChild
while(TreeNode)
{
treeNode.AOTsetProperty("M
TreeNode.AOTcompile();
TreeNode.AOTsave();
TreeNode=TreeNode.AOTnextS
pause;
}