Yes, easy.
have an extra PROCESSING table to save the temporary journal.
make sure it balances (adds to zero), before permitting it to be processed
then update your main transaction tables, and clear down the temp table.
-------------
a tip
Is this a "high-endish" system. If so, allow for a flag somewhere to make this journal reversing - so you can use it to post period end accruals, and reverse them into the next month automatically.
-----------
another tip - Have TEXT general ledger/NL account codes, rather than numeric - even if you only use numerics. You will find extracting sorted data (P&L/BS) becomes far easier.
----------
out of interest, I wrote a pretty good NL for myself in about 2 days. It's a nice project, because the scope is fairly closely defined