Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Unanswered

RetrieveRecordChange History Issue(The property provided was of type Microsoft.Xrm.Sdk.EntityReference, when the expected was of type Microsoft.Xrm.Sdk.Entity)

(0) ShareShare
ReportReport
Posted on by 195

Hi,

RetrieveRecordChangeHistory webapi call is throwing below exception:

pastedimage1599216117010v8.png


https://xxxxxxxx.crm.dynamics.com/api/data/v9.1/RetrieveRecordChangeHistory(Target=@p1)?@p1=%7B%27@odata.type%27:%27Microsoft.Dynamics.CRM.knowledgearticle%27,%27knowledgearticleid%27:%20%278876c3e7-53fb-44a6-b2d6-2a00d5c43d24%27%7D

When I change Guid  in above url for few records it is working fine but for few getting the  

The property provided was of type Microsoft.Xrm.Sdk.EntityReference, when the expected was of type Microsoft.Xrm.Sdk.Entity  error.

  • Susritha Profile Picture
    Susritha 195 on at
    RE: RetrieveRecordChange History Issue(The property provided was of type Microsoft.Xrm.Sdk.EntityReference, when the expected was of type Microsoft.Xrm.Sdk.Entity)

    I also want to see the records audit history even  they have associated 1:N or N:N record.Is there any way to see it

  • cloflyMao Profile Picture
    cloflyMao 25,202 on at
    RE: RetrieveRecordChange History Issue(The property provided was of type Microsoft.Xrm.Sdk.EntityReference, when the expected was of type Microsoft.Xrm.Sdk.Entity)

    Hi Susritha,

    It seems that you had performed association or disassociation operation between the target knowledgearticle entity and another entity.(1:N or N:N)

    e.g:

    I have a contact, and I removed him from a specific marketing list, then system will create a new event record called "Remove Members" in related audit history records.

    3122.JPG

    Before the record is created, the web api was able to execute successfully, however, after creation of record, I encountered same error as yours. 

    Please remove any association or disassociation audit records of the target record, or take a record which only has CRUD operations to test the api again.

    Regards,

    Clofly

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

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

Tip: Become a User Group leader!

Join the ranks of valued community UG leaders

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,403 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans