IMDD and Transaction Processing

by Unknown user

There was a recent news group thread on the In-Memory file driver and transactions.

The Memory driver does not support Transacation processing. The on-line help, though I did have to go looking for it, makes this clear:

Figure 1: Supported Commands and Attributes

While I do not know this from experience, I suspect that attempting to Logout an IMDD file:

LOGOUT(1, myIMDDfile)

would trigger Clarion's built in notification system. That is, the compiler would puke and throw an error.

However, and this is very easy to forget, Transaction processing is also used in the standard Form template.

To satisfy yourself on this, create a Form procedure that updates an IMDD file. Call the form up to insert a new record. But, instead of completing the insert, press the Cancel button.

Figure 2: Cancelling Insert on an IMDD file

To make this a bit more fun, it only seems to happen the first time I press Cancel. After pressing "OK" on the "Transaction Cancelled" message, the Cancel button works. If I try to Insert another record and cancel that operation, no message (I do so love consistency ...).

Fortunately, preventing this message from ever appearing – even just the once – is simple enough. Remembering to implement the fix, well, that's a different matter.

Select the Global Properties tab and press the Actions button ... Individual File Overrides and find the IMDD file(s). Press the Properties button and turn off template-based Transactions:

This must be done for each IMDD file in the dictionary.

It would be better if this option were available in the Dictionary Editor. It would be better still if the templates were intelligent enough to by-pass Transaction processing when there's an IMDD file involved, especially as the Form's primary. But, there is a solution and it works.