Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

by Unknown user

The In-Memory Database Driver, a/k/a IMDD, a/k/a "the Memory Driver," is perhaps the best-received Clarion add-on in recent history. I certainly consider it a "must have." I am currently working on a project using a version of Clarion for which no one, including SoftVelocity, has an IMDD install. While I can use queues, of course (the Memory Driver appears to be "just" a file driver wrapper for queues), my inability to have IMDD files in my dictionary is a constant source of frustration.

Why is the Memory Driver so popular?

  • It allows use of standard file I/O commands for my queues.
  • IMDD files, like queues, allow completely private data. Data declared globally can be seen only by the app in which it is declared; data declared in lower scopes are invisible to other modules/procedures in the same app. As the on-line help asserts:

...

I have never tested this claim myself but a number of very knowledgeable Clarioneers also make this claim. And, knowing many of them, I am inclined to believe they did not agree with the thread-safe claim simply because SoftVelocity said it.
There is even a template that allows synchronizing an IMDD file with its underlying disk file. But I have never used it.

IMDD's Latest Feature


Recently, "threaded content" (the subject of this article) was added to the IMDD. In fact, very recently, a question came up about this driver string on the news groups.

...

The documentation implies that, with "ThreadedContent," IMDD data is not only invisible to other instances of the application but also invisible to any procedure on a different thread.
Testing this claim seems easy enough.

Testing "ThreadedContent"


I intended to wizard up an app based on a DCT containing one file only, an IMDD file, and "ThreadedContent" will be switched on for that file.

...

(where "Thread" is a local Long) to display on the browse window. This will confirm that I am on different threads.

The Proof of the Pudding


Run the attached app, downloadable at the end of this article. It is an 8.0.8973 app and the app tree will show that it is a wizarded app. The compiled EXE is compiled in "Lib" ("Local") mode so everyone can run it.
When you run the app, you should be able to get results similar to this:

...