[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sqlite3

From: Jean Louis
Subject: Re: sqlite3
Date: Mon, 14 Feb 2022 15:04:37 +0300
User-agent: Mutt/2.2.0 (2022-02-12)

* Lars Ingebrigtsen <larsi@gnus.org> [2021-12-06 04:52]:
> I've brought this up before, but I didn't really have a solution then,
> but I think I do now: sqlite3.

That is great idea to have that built-in into Emacs or as build option
to include it.

Another pending project that wants to enter into ELPA is this module
for PostgreSQL, though developer may be delayed, we discussed it
months ago and they agreed. I am using PostgreSQL all the time.

emacs-libpq @ Github

> sqlite3 is supported on more platforms than Emacs is, the interface is
> small and stable, and (best of all) somebody has already created
> interface functions for Emacs (via a module):
>   https://github.com/syohex/emacs-sqlite3

Not just sqlite3, I would prefer to have the gdbm as well, and Emacs
lisp interface to create, delete, databases and keys and values.

> I think it'd be good to bring that into core, and then write a small
> wrapper library (well, a trivial ORM) for the rest of Emacs to use, so
> that we don't have to write SQL all over the place.

I hope you will leave the option to write SQL as well.

> (setf (persistent-data :namespace "emoji" :key "favorites")
> emoji--favorites)

Excellent idea! Though consider also including various other
databases, such as lmdb, qdbm, gdbm, bdb, tokyocabinet, kyotocabinet
and similar.

As if you only target remembering specific information thatn SQL may
be overkill, and gbdm can be good enough.

> I.e., what Emacs needs is a persistent key/value store, and this would
> give us that.

Great idea! 

> In addition, if somebody really wants to write SQL stuff (it can be
> very handy for some things), having sqlite3 in there gives us that
> in addition for free.


Please include possibilities to bind to any kind of databases. I am
using heavily PostgreSQL, though GDBM and other databases are welcome. 

> This comes with questions about how the users are supposed be able to
> clear out the data, for instance, but we could have a `M-x
> list-persistent-data' where the users could blow out whatever they want
> to.

I hope that database included may be useful for users in any other
form, freely, not only for the specific persistent data you proposed.


Take action in Free Software Foundation campaigns:

In support of Richard M. Stallman

reply via email to

[Prev in Thread] Current Thread [Next in Thread]