in an ASP.NET/C# project I am developing, all changes (inserts/updates/deletes) are required to be auditted into a seperate table, along with the primary key. There is one hurdle which I can't seem to overcome however.
For the updating, I am capturing the ModifiedMemberInfo and making a string to audit out of that - an example is below:
foreach (ModifiedMemberInfo mmi in dc.Jobs.GetModifiedMembers((Job)Table))
{
ActionToAudit += LINQChangeActionDetails(mmi);
AuditDesc = "Modified Job details";
}
Problem is, I need to audit that jobs primary key too - but how do I access it?
Ended up creating a dictionary containing the relevant column descriptions