Re: [sqlite] Running in memory only

2005-08-31 Thread Joel Lucsy
On 8/31/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
> I would like to know if it is possible to have an instance of sqlite
> running in RAM only? My aim is to build a small but fast memory SQL
> storage.

How about using the database called ":memory:". Unless this has been
removed when I wasn't looking, this would probably be the "easiest"
way.

-- 
Joel Lucsy
"The dinosaurs became extinct because they didn't have a space
program." -- Larry Niven


Re: [sqlite] Running in memory only

2005-08-31 Thread benjamin . filippi
Thanks guys I will investigate those features.

Benjamin Filippi
Capital Fund Management
6 boulevard Haussmann 75009 Paris
Tel: +33 1 49 49 59 30
Fax: +33 1 47 70 17 40
[EMAIL PROTECTED]
http://www.cfm.fr




Ben Clewett <[EMAIL PROTECTED]>
08/31/2005 10:41 AM
Please respond to sqlite-users
 
To: sqlite-users@sqlite.org
cc: 
Subject:        Re: [sqlite] Running in memory only


Benjamin,

This works well on Linux using file system /dev/shm.  This should be 
installed as default and works indistinguishably from normal file 
system.  SQLite writes about 200 times faster than normal file system.

Remember that like all ram disks, this is wiped without warning on 
shut-down.  So consider it only for duplicate data.  I also find having 
an 'rc' script to re-create tables on startup is a great help.

David Pitcher wrote:
> Salut Benjamin,
> 
> Simplest way to make that happen is to use a ram disk, google for 
> 'RamDisk' and the platform you are using. Then you can use the existing 
> sqlite binary/library but all I/O occurs in memory.
> 
> When you want to persist, you just copy it to a hard disk...
> 
> D.
> 




Re: [sqlite] Running in memory only

2005-08-31 Thread Ben Clewett

Benjamin,

This works well on Linux using file system /dev/shm.  This should be 
installed as default and works indistinguishably from normal file 
system.  SQLite writes about 200 times faster than normal file system.


Remember that like all ram disks, this is wiped without warning on 
shut-down.  So consider it only for duplicate data.  I also find having 
an 'rc' script to re-create tables on startup is a great help.


David Pitcher wrote:

Salut Benjamin,

Simplest way to make that happen is to use a ram disk, google for 
'RamDisk' and the platform you are using. Then you can use the existing 
sqlite binary/library but all I/O occurs in memory.


When you want to persist, you just copy it to a hard disk...

D.





Re: [sqlite] Running in memory only

2005-08-31 Thread David Pitcher

Salut Benjamin,

Simplest way to make that happen is to use a ram disk, google for 'RamDisk' 
and the platform you are using. Then you can use the existing sqlite 
binary/library but all I/O occurs in memory.


When you want to persist, you just copy it to a hard disk...

D.