TZ
Hello all,
I am trying to do a research of some ObjDef in an ARIS Report Script. I would like to operate a search on a Database but I would like to filter my search to a specific group. Is this something that is possible? Here is what I tried to do but it is not working somehow.
I even get an error that createSearchItem
is not present in the Database
object
function getRegulationsFromGroup(group) {
const searchItem = group.Database().createSearchItem(
Constants.OT_TYPE, // AttrTypeNum
g_nLoc, // LocaleId
group, // sAttributeValue
Constants.SEARCH_CMP_EQUAL, // comparisonMethod
true, // bCaseSensitive
false // bAllowWildcards
);
var regulationsArray = group.Database().Find(
Constants.SEARCH_OBJDEF, // SearchKind
Constants.OT_CLST, // itemTypes
searchItem // searchItem
);
return (regulationsArray);
}