Specifications

CHAPTER 19 Controlling Updates in Forms
Users Guide 535
Specifying the WHERE clause for update/delete
Sometimes multiple users are accessing the same tables at the same time. In
these situations, you need to decide when to allow your form to update the
database. If you allow your form to always update the database, it could
overwrite changes made by other users:
You can control when updates succeed by specifying which columns
InfoMaker includes in the
WHERE clause in the UPDATE or DELETE statement
used to update the database:
UPDATE table...
SET column = newvalue
WHERE col1 = value1
AND col2 = value2 ...
DELETE
FROM table
WHERE col1 = value1
AND col2 = value2 ...
Using timestamps
Some DBMSs maintain timestamps so you can ensure that you are working
with the most current data. If the
SELECT statement for the form contains a
timestamp column, InfoMaker includes the key column and the timestamp
column in the
WHERE clause for an UPDATE or DELETE statement regardless
of which columns you specify in the Where Clause for Update/Delete box.
If the value in the timestamp column changes (possibly due to another user
modifying the row), the update fails.
To see whether you can use timestamps with your DBMS, see Connecting to
Your Database.
Choose one of the options in Table 19-1 in the Where Clause for Update/Delete
box. The results are illustrated by an example following the table.