In Install & Configuration Manual I read that for avoid lock it’s possible use LOCKTABLE(TRUE, TRUE) in this way: Read Data; LOCKTABLE(TRUE,TRUE); Compute Data; Modify Data; But when we call MODIFY this check that the version it’s the same before update the record and if the version it’s change an error is returned. In other words the behavior it’s the same even if the LOCKTABLE(TRUE,TRUE) it’s not call because the MODIFY check the timestamp of the record and if this it’s change an error is returned. Therefore I have not understood the usefullness of the Locktable(TRUE, TRUE) Hello everyone and excused mine terrible english.
If you lock the table before you read the data, it will work fine: LOCKTABLE(TRUE,TRUE); Read Data; Compute Data; Modify Data;
OK but the question is if I do Read Data; Compute Data; Modify Data; when I call the MODIFY and the record is changed I have the same error that I have if I do: LOCKTABLE(TRUE,TRUE); Read Data; Compute Data; Modify Data;
put your code in here. It looks like in your validation, another variable modifies the same record.
The question is born when I study Install & Configuration and I have do a code like this LOCK(TRUE, TRUE ) on Customer; Read a customer; Display a message for a question; > With Custormer card I modify the customer; Change a field of customer; Call MODIFY on Customer; I have the error and this is correct But If do Read a customer; Display a message for a question; > With Custormer card I modify the customer; Change a field of customer; Call MODIFY on Customer; I have the same error (and this it’s correct) but therefore to what it serves the LOCKTABLE(TRUE,TRUE)?