How to change keys during Rename

i All, I have written a dataport that will rename the G/L Account. The dataport works fine except for the fact that when Renaming the G/L Account, NAvision goes to the G/L Entry table, VEndor LEdger Entry table etc to update the G/L Account No. reference. The problem that I have is that Navision by Default searches based on the Primary key, Is there anyway that I can change the key that the G/L Entry table uses when updating the G/L Account No. reference. I looked at the OnRename trigger but except fro the Last Modified DAte update there is no other code. What I want to do is when NAvision is trying to update the G/L Account No. field in the G/L Entry table, change the key reference to something other than the Entry No. that is uses by default. Is this even possible? I am trying to do this in Navision FInancials 2.60. Any help would be greatly appreciated. Thanks, Anu

No, this is not possible, I’m afraid (unless you actually change the primary key in the related tables). You can, of course, write your own renaming routine. BTW a dataport seems like a strange choice for this task?

The reason I had a dataport is because the client wanted to rename all the G/L Accounts. So, the easiest way for me was to write a dataport and have logic built into it for other validations. The dataport works pretty well, it’s just the keys. Thanks for the input.

normally, I use report to do this task.