Hi
Have a NAS that seems to cache the data in tables.
We run a SQL2000 and Nav 4.0
What we do is that we have a NAS that imports files from the disk.
From the file we generate an sales header and multiple sales lines
Everything works fine exept this.
If a user changes the "Unit Price" on the Item card, the NAS still picks the old price.
The old price does not exist anyware in the system. It's like the data is cached and never released.
This is some pseudo code to explain what we do
codeunit 1, check parameter, call codeunit 50000
Codeunit 50000, start a timer and do a loop
In timer-loop, check if any new file exist to import, if so, do a clear on the variable for codeunit 50001
Codeunit 50001, import the file. Use local parameters. Use validate on all fields on the sales line. Both the No., Quantity, UoM fields should call the price calc mgmt, and they do, but recieves the old price.
If i Stop the service and restart it, everything work fine.
If I open up the imported order in a clinet and press F2 in No. and then enter, the correct price is recieved.
anyone have any idea why it behaves like this?
Additional note:
We also changed a vendor some time ago, and changed the Gen. Bus. Posting Group.
This change did go through and the correct data was recieved.
0
Comments
Regards
The singleinstance feels like a longshot. Since i do a clear on the codeunit and i'm pretty certain that i don't have multiple instances of it, I can't see how that would help.
The SELECTLATESTVERSION seems like the thing to use.
I'm not sure i can recreate the error but I will test it later today. If i'm not able to recreate it I will have to wait until the cache have grown up big enough to generate the error. But if the SELECTLATESTVERSION works, I will never get this error again.
Anyway. I will make a new post when I made the tests