Autoinc key fields in a Paradox multiuser database - URGENT
Posted on 2000-05-09
I have a program that runs on four computers, using the same database. I've set the NetFileDir and PrivFileDir properties to the correct places on the net.
When one station appends a record on a table at the same time another station is appending a record on the same table, both get the same value for the autoincrement field. As it is part of the key, I got a Key Violation.
The AfterPost event of all my tables is calling the FlushBuffers method, and CachedUpdates is False. The sequence to include records is:
- call the tables's Refresh method
I'll try to use LockTable (read and write), but I'm not sure it will work. I've heard about the BDE OnChangeNotify, but don't know if it can help.
I need an urgent answer, because I must end this work in two days!