Remix.run Logo
buckle8017 5 days ago

It should be a timestamp of the last time the email was verified.

It's a surprisingly useful piece of data to have.

amelius 5 days ago | parent [-]

Even more useful is a log of all the changes in the database. This gives you what you want, and it would be automatic for any data you store.

So, keep the Boolean, and use a log.

aydyn 5 days ago | parent [-]

No? So you have to look at database history to extract information you think is useful?

That's a terrible database design.

amelius 5 days ago | parent [-]

It's the basis behind Datomic, if I'm not mistaking.

You can easily search through history. The point is, it is better to do this in the design of the database than in the design of the schema.

So: "No?" -> "Yes!"

aydyn 5 days ago | parent [-]

Okay, but for something like SQL this seems like a bad idea.