When the process reaches a wait-state (eg. userTask) the process-variables and execution-state are stored in the DB and the DB-transaction is commited. When the user eventually completes the task, a new transaction is started and the process flows on in that transaction untill the next wait-state or process-end.
So the transaction doesn't run over the whole process if the process contains waitstates (or in the furture, asynchronous continuations).
Hope this makes sense
Cheers,