all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Christopher Dimech <dimech@gmx.com>
To: Jean Louis <bugs@gnu.support>
Cc: help-gnu-emacs@gnu.org, Eric S Fraga <e.fraga@ucl.ac.uk>
Subject: Re: Designing people and organization management for Emacs
Date: Fri, 4 Dec 2020 17:09:46 +0100	[thread overview]
Message-ID: <trinity-d360e724-eff4-42c7-b321-eac3247c9ae9-1607098186811@3c-app-mailcom-bs11> (raw)
In-Reply-To: <X8pUBCysKmFEhPXz@protected.rcdrun.com>

> Sent: Friday, December 04, 2020 at 4:21 PM
> From: "Jean Louis" <bugs@gnu.support>
> To: "Christopher Dimech" <dimech@gmx.com>
> Cc: "Eric S Fraga" <e.fraga@ucl.ac.uk>, help-gnu-emacs@gnu.org
> Subject: Re: Designing people and organization management for Emacs
>
> * Christopher Dimech <dimech@gmx.com> [2020-12-04 17:52]:
> > > Yes. I was using text files and spreadsheets, bbdb. Before many years
> > > I switched to database backed management of any data that is
> > > structured. And no, org-contacts or BBDB cannot replace the power of
> > > SQL databases. 204111 contacts are in my database each available at
> > > few key presses related.
> >
> > What would happen for things were database model does not fit the
> > data?
>
> Model is designed based on data to enter in the future. If data
> changes in the future it is very easy to change the model. Good
> example with my experience is that few people that I know over long
> span of years changed their email addresses multiple times. But I do
> like to have capability to keep those obsolete email addresses as they
> are still related to the person and emails of the person. By using
> person's ID I can quickly access all email files. But if I have only 3
> fields for email addresses I have no space for 4th and 5th field.

I meant, could users be able to set their own models?

> Some people make extra table for emails that are related to contact. I
> like keeping most of information in the contacts (people) table. So
> what do I do?
>
> One option is that I simply add new column to the table where I would
> store those obsolete email addresses. That column need not be queried
> to find the "valid" email address. So I do like this:
>
> ALTER TABLE data1 ADD COLUMN data_emailsobsolete TEXT[];
>
> That solves the problem, there is new column for obsolete emails. Let
> me insert few:
>
> admin=# INSERT INTO data1 (data_emailsobsolete) VALUES ('{new@example.com,more@example.com}');
> INSERT 0 1
> admin=# SELECT data_emailsobsolete FROM data1;
>         data_emailsobsolete
> ------------------------------------
>
>  {new@example.com,more@example.com}
> (2 rows)
>
> With that simple SQL instruction problem is solved for many years in
> advance as the data influenced the model. But user can change to model
> to anything one wants.
>
> To find specific person's ID by using some of obsolete emails is easy:
>
> SELECT contacts_id FROM contacts WHERE 'new@example.com' = ANY (contacts_emailsobsolete);
>         data_emailsobsolete
> ------------------------------------
>  {new@example.com,more@example.com}
> (1 row)
>
> This is then used by Emacs Lisp function such as:
>
> (contact-find-id-by-email "new@example.com")
>
> I am often searching for valid emails as such I need to contact
> people and I used to have 3 booleans fields which say if email address
> is valid. Sometimes they become valid again after not being valid for
> some time.
>
> In general databases are very easy to adapt to any models.
>
> Jean
>



  reply	other threads:[~2020-12-04 16:09 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-03 20:15 Designing people and organization management for Emacs Jean Louis
2020-12-04  9:56 ` Eric S Fraga
2020-12-04 13:12   ` Pankaj Jangid
2020-12-04 13:38   ` Jean Louis
2020-12-04 14:52     ` Christopher Dimech
2020-12-04 15:21       ` Jean Louis
2020-12-04 16:09         ` Christopher Dimech [this message]
2020-12-04 16:20           ` Eric S Fraga
2020-12-05  3:14             ` Pankaj Jangid
2020-12-06 15:41               ` Eric S Fraga
2020-12-04 16:26           ` Jean Louis
2020-12-04 16:42             ` Christopher Dimech
2020-12-04 17:56               ` Jean Louis
2020-12-04 18:05                 ` Christopher Dimech
2020-12-04 18:23                   ` Jean Louis
2020-12-04 19:43                     ` Christopher Dimech
2020-12-04 21:21                       ` Jean Louis
2020-12-05  6:11                       ` Jean Louis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=trinity-d360e724-eff4-42c7-b321-eac3247c9ae9-1607098186811@3c-app-mailcom-bs11 \
    --to=dimech@gmx.com \
    --cc=bugs@gnu.support \
    --cc=e.fraga@ucl.ac.uk \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.