>
>
> > I want to save sqlite database as a entry of the dbm.
>
> If you really have to store the sqlite databases as blobs, why not store
> them in yet another sqlite database as a blob instead of inside dbm?
> SQLite has the drawback of not letting you resize a blob (you have to
> create a new value with the new length) but it doesn't look like the dbm
> api lets you either.  Unless your dbm implementation has proper
> transactions you could also lose data.
>

Some dbm implementations support transaction.
Such as tokyocabinet.


>
> > For example, the user's addressbook save in a sqlite database,
> > and the buffer of the database may be store in a dbm.
>
> That example would definitely be done better using more tables and
> normalization (users don't like addressbooks to be unreliable).  I
> assume there is more to it that you have told us.
>

For addressbook application, it call select_all_address_for_one_user
frequency.
If multipile users' addresses store in one table,  the
select_all_address_for_one_user
will cause much I/O operations. If it use a dbm to store the the
buffer_of_database,
the select_all_address_for_one_user is very fast.
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to