Hi folks,
Just wondering if anyone has faced issues trying to retrieve the audit trail using SDK, which seems to be a problem regarding dirty reads. Some audit records are retrieved even for uncommitted transactions which might be roll backed depending on business validations in plugins, etc. Just to give you some background, I have a custom job that replicates the audit trail to another database (it runs at every 2 minutes), and I've been facing issues with mismatching if you compare the databases. The other database has more entries than CRM's database due issue above.
I am using QueryExpression and even setting the NoLock property to false, it is just ignored by the SDK. If you query directly against the CRM database, you can retrieve just commited audit entries, which is what I want to do using SDK. I don't want to change my job to query against the CRM database, as it might move to cloud in the future.
I've noticed that even using the CRM User Interface on the audit summary, the behavior is the same (dirty reads).
Any thoughts would be appreciated,
Thanks.
*This post is locked for comments
I have the same question (0)