Hi Alex,

On Wed, 12 Sep 2007 12:19:44 +0200, you wrote:

> I have 3 questions regarding sqlite database loaded/used whilst in memory:
>
> 1. How can an sqlite database file (example file1.db) be 
>    loaded in memory?
>  (Is this the answer?: > sqlite3.exe file1.db)

sqlite3 file1.db .dump | sqlite3 :memory:
The default database (no name specified) is in memory, so:
sqlite3 file1.db .dump | sqlite3
would do the same.

> 2. How can the in-memory sqlite database be accessed
>    by multiple applications?

No. The only way to do that would be to construct a 'server
wrapper' around sqlite and have applications (clients) connect
to that server. It has been done before, for example, there is
an ODBC wrapper.
http://www.sqlite.org/cvstrac/wiki

>3. Can multiple threads or applications access simultaneously
>   the same in-memory sqlite database?

Not without the server mechanism.

The performance gain of a :memory: database is limited, one of
the reasons is that most operating systems will cache the
database file in memory anyway.

In general: when you really need a DB server, don't use SQLite.
http://www.sqlite.org/whentouse.html

>Thank you.

Regards,
-- 
  (  Kees Nuyt
  )
c[_]

-----------------------------------------------------------------------------
To unsubscribe, send email to [EMAIL PROTECTED]
-----------------------------------------------------------------------------

Reply via email to