emacs-orgmode
[Top][All Lists]
Advanced

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

Re: SQLite for contacts and relations to Org - Re: contact management in


From: Jean Louis
Subject: Re: SQLite for contacts and relations to Org - Re: contact management in emacs
Date: Tue, 11 Oct 2022 22:59:51 +0300
User-agent: Mutt/2.2.7+37 (a90f69b) (2022-09-02)

* Sébastien Rey-Coyrehourcq <sebastien.rey-coyrehourcq@univ-rouen.fr> 
[2022-10-11 08:56]:
> Hi Jean Louis,
> 
> First i want to thank you for this very detailled explanation, this is very 
> valuable for someone that start in elisp like me.
> 
> Secondly, i found the idea of using sqlite for contacts very interesting, and 
> i think a lot on this solution on my side the last weeks. With the new emacs 
> interface to sql, it was easy i suppose to create a “both-way” syncing tool 
> between org-contact (to easily maintain info, linking to notes, agenda, etc.) 
> and a database that anyone could reuse, move, send also using mobile phone.
> 
> I use org-roam that use both of the two world, database and org, in the light 
> of recent discussion, why we cannot do the same things for org-contact ? 
> Linking / syncing properties with unique hash/id also stored in a database. 
> If you have 150000 contact, with 150000 unique ID, and if you want to create 
> an org-contact file/propertie into an org document, that’s probably easy to 
> inject and maintain some sort of syncing (like org-roam do) between the info 
> in database and the info into some properties block no ?

That is exactly the point. Why keep well structured information such
as phone numbers, emails, addresses, in Org file, when structured
information by its type belong into structured forms like databases.

Keeping it in Org or any text files is not scalable, not usable, not
shareable. To tell people to use text files to keep information is
detrimental for people who listen to it. They can't know it
immediately, but one day they will realize that it does not fly.

Why email clients like Thunderbird have contacts features built-in?
For reason that contacts are related to communication and
information. Communication is connection in every relation between
people. Information is written because it fosters communication and
thus relations.

Org contacts try to store contacts into Org file. I don't know the
rest. I have looked inside the Org contacts code and I do not agree
with the design. It is not scalable.

>From code:

,----
| To enter new contacts, you can use `org-capture' and a minimal
| template just like..
`----

;; this:

;;         ("c" "Contacts" entry (file "~/Org/contacts.org")
;;          "* %(org-contacts-template-name)
;; :PROPERTIES:
;; :EMAIL: %(org-contacts-template-email)
;; :END:")))
;;
;; You can also use a complex template, for example:
;;
;;         ("c" "Contacts" entry (file "~/Org/contacts.org")
;;          "* %(org-contacts-template-name)
;; :PROPERTIES:
;; :EMAIL: %(org-contacts-template-email)
;; :PHONE:
;; :ALIAS:
;; :NICKNAME:
;; :IGNORE:
;; :ICON:
;; :NOTE:
;; :ADDRESS:
;; :BIRTHDAY:
;; :END:")))

;;;; Usage:

;; How to search?
;; - You can use [M-x org-contacts] command to search.

I would not bother using that. Why? Because of experience.

- many people have many various emails, not just one. 

- by using email as reference, I quickly jump to list of conversations
  with that person

- if email is invalid, I still need the conversation retained

- I must know if email is for work or private, it needs more structure

- phones, I am sending SMS, I must know in structured way, if the
  phone belongs to provider ABC or XYZ, as that decides on routing on
  how to send SMS messages. Nobody likes spending money by using wrong
  providers. 

- fax is phone line, mobile phone and fixed lines are not same, I must
  know type of phone line;

- aliases and nicknames belong to identities,

- single note about contact is not enough, contact may be related to
  many notes.

- address must be structured, otherwise it is really difficult to use
  it programmatically:

                             ID   198333
                   Date created   "2022-10-11 21:28:42.565176"
                  Date modified   nil
                   User created   "maddox"
                  User modified   "maddox"
                         Person   "Joe Doe"
                           Type   "Default address"
                   Address Name   "Address in Germany"
                        Line #1   ""
                        Line #2   ""
                        Line #3   ""
                           City   ""
                         Region   ""
                      Post code   ""
                        Country   "GERMANY"
                 Date validated   nil
                       Location   nil
                    Description   nil
                       Inactive   nil
                        Default   nil

There is no option but to keep structured information in structured
databases. I have working system with PostgreSQL and decentralized
collaboration, but I am now making SQLite minimized version, so when
package is finished I will let you know.

Package preparation:
https://gnu.support/images/2022/10/2022-10-11/Screenshot-2022-10-11-22-50-03-955596051.png

Editing of entry:
https://gnu.support/images/2022/10/2022-10-11/Screenshot-2022-10-11-22-57-51-793932307.png


-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

In support of Richard M. Stallman
https://stallmansupport.org/



reply via email to

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