3 of 3 people found this helpful
The information about whether a node in a model was saved by a user, and whether it caused the model to go into review suggested state is stored in attributes on the DefinitionContainment relationships. user_saved is set True if the user saved the node in the model; review_suggested is set True if the node caused it to be put into review suggested. Both can be not set if the condition is not true, rather than set to False.
This query gives the result you want. It's not very likely to be a short list, however. (The strange-looking double not expression is used to convert review_suggested from not-set to false.)
search flags (find_relationships) DefinitionContainment
where not user_saved and #:IncludedItem:.name
nodeLink(#:Definition:ModelDefinition, #:Definition:ModelDefinition.name) as "Model Definition Name",
nodeLink(#:IncludedItem:, #:IncludedItem:.name) as "Item added by BMC Discovery",
(not not review_suggested) as "Review Suggested"
Revisiting this thread again now, as one of my customers have a usecase where they need to notify model owners when the models are set to "Review Suggested". I'm thinking this probably could be done with a pattern resulting in sending an email to the email of the model owner, but what would be the triggering condition? Is it even possible to trigger on the Review Suggested flag?
The easiest way to do it would be to trigger on ActivityRecord being created where needs_attention is true.
Thank you! I'll give that a try