beginner's question

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

beginner's question

Lloyd Dupont
a question about sqlite3.exe

reading some documentation aboit it I see you could have memory database.
how do I create them?
or attach them?
Reply | Threaded
Open this post in threaded view
|

Re: beginner's question

Ulrik Sandborg-Petersen
Hi,

Lloyd Dupont wrote:

>a question about sqlite3.exe
>
>reading some documentation aboit it I see you could have memory database.
>how do I create them?
>  
>
I'm not sure about Windows, but on Unix/Linux, it is:

sqlite :memory:

>or attach them?
>
>  
>
You issue the statement

ATTACH DATABASE ':memory:' AS mynameforthememorydatabase;

HTH

Ulrik P.


--
Ulrik Petersen, PhD student, MA, B.Sc.
Aalborg University, Denmark
http://ulrikp.org/

Reply | Threaded
Open this post in threaded view
|

Re: beginner's question

Allan Wind
In reply to this post by Lloyd Dupont
On 2005-06-05T17:03:12+1000, Lloyd Dupont wrote:
> reading some documentation aboit it I see you could have memory database.
> how do I create them?  or attach them?

http://www.sqlite.org/cvstrac/wiki?p=InMemoryDatabase seem to suggest
that you pass in ":memory:" as the first argument to sqlite3_open.
connect if you use different language bindings.

The API reference should be updated to reflect this, please file a
ticket on it.


/Allan

signature.asc (196 bytes) Download Attachment