That is, in your application, you should have a transaction table,
and transactions should have a certain state, and a certain lifecycle,
which you can define as appropriate for your application.
Then, when a user is editing a transaction, you update the transaction
state in your transaction table to reflect that this transaction is
currently being edited by this user.
And, when you want to build a list of transactions which are not
currently being edited, you run a select statement which fetches
the rows from your transaction table which are in the appropriate state.
thanks,
bryan
P.S. Regarding the low-level DBMS transaction, I agree with what others
have already said: keep them short and focused; don't hold them open
across UI think periods. Fetch some data from the database, update things
as necessary to reflect that a user is currently working with this data,
then commit that DBMS transaction. Later, when the user issues some
command in the UI, use a separate DBMS transaction to return to those
records and process them accordingly.