Skip to main content

Notifications

Power Apps - Microsoft Dataverse
Unanswered

Delete Audit record based on attributemask update

(0) ShareShare
ReportReport
Posted on by

Hi,

I would like to create a bulk deletion job when only a specific attribute its updated.

 

So having these 2 audit records attributemask updates, only second record should be deleted.

Audit record 1 - "attributemask":"42,18,179"

Audit record 2 - "attributemask":"42"

 

I'm using the PA Dataverse action - Perform an unbound action

Jorge_0-1687870534041.png

But not able to make it work when I try to include the attributemask filter

 

Tried with this, but the job is not created successfully in Dataverse

 

 

[
 {
 "EntityName": "audit",
 "Criteria": {
 "FilterOperator": "And",
 "Conditions": [
 {
 "AttributeName": "objecttypecode",
 "Operator": "Equal",
 "Values": [
 {
 "Type": "System.String",
 "Value": "contact"
 }
 ]
 },
 {
 "AttributeName": "userid",
 "Operator": "Equal",
 "Values": [
 {
 "Type": "System.Guid",
 "Value": "f79071df-83ec-ec11-bb3d-0022489fbc1b"
 }
 ]
 },
 {
 "AttributeName": "attributemask",
 "Operator": "Equal",
 "Values": [
 {
 "Type": "System.String",
 "Value": "42"
 }
 ]
 }
 ],
 "Filters": []
 }
 }
]

 

 

Jorge_1-1687873839746.png

 

When I try to do similar call with the Web API

https://crm.api.crm4.dynamics.com/api/data/v9.2/audits?$filter=auditid%20eq '16FB7981-B30F-EE11-907C-0022489D5940' and attributemask eq '42'

{"error":{"code":"0x80040265","message":"Equal and Not Equal operations are not supported on Attribute Mask"}}

 

 

Categories:
  • Jorge_ Profile Picture
    Jorge_ on at
    Re: Delete Audit record based on attributemask update

    Hi, anyone can help on this please?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,304

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,703

Leaderboard

Featured topics