Hacker News new | past | comments | ask | show | jobs | submit | b-man's comments login

Anything you would recommend instead?


Recommend for what? For learning about the actual history of time? Start here:

https://en.wikipedia.org/wiki/Time

There are 113 references, those should keep you busy for a while.


why?


  Location: EST
  Remote: Yes
  Willing to relocate: Yes
  Technologies: F#, C#, C, PostgreSQL, Java, Clojure, Common Lisp, Scheme, Emacs Lisp, SQL, Python, Ruby, JS, AWS, Linux
  Résumé/CV: https://www.linkedin.com/in/eduardo-bellani/
  Email: ebellani -@- gmail.com


anything in particular?


  Location: EST
  Remote: Yes
  Willing to relocate: Yes
  Technologies: F#, C#, C, PostgreSQL, Java, Clojure, Common Lisp, Scheme, Emacs Lisp, SQL, Python, Ruby, JS, AWS, Linux
  Résumé/CV: https://www.linkedin.com/in/eduardo-bellani/
  Email: ebellani -@- gmail.com


  Location: EST
  Remote: Yes
  Willing to relocate: Yes
  Technologies: F#, C#, C, PostgreSQL, Java, Clojure, Common Lisp, Scheme, Emacs Lisp, SQL, Python, Ruby, JS, AWS, Linux
  Résumé/CV: https://www.linkedin.com/in/eduardo-bellani/
  Email: ebellani -@- gmail.com


Just use temporal tables. It would cover all the cases you brought up.


This thing? https://learn.microsoft.com/en-us/sql/relational-databases/t...

Are not we talking about PostgreSQL?


Temporal tables are an implementation of one of SQL 2011's main features: system time.

https://sigmodrecord.org/publications/sigmodRecord/1209/pdfs...

Postgres itself has not yet added such to the core, since it moves about as fast as an elephant. There are extensions that do implement it (https://wiki.postgresql.org/wiki/Temporal_Extensions).


Help me here please. I really do not see how

WHERE CURRENT_TIMESTAMP BETWEEN start AND end is much better than WHERE deleted_at IS NOT NULL

Also, if we are talking about real use case of audit, not a simplified artificial one, my real tables were more like

changeset(id INT, timestamp DATETIME, user ^USER, host TEXT, ip_address TEXT, <other security data>)

datatable1(id INT, created_at ^changeset, updated_at ^changeset, deleted_at ^changeset NULL, <other fields>)

datatable2(id INT, created_at ^changeset, updated_at ^changeset, deleted_at ^changeset NULL, <other fields>)

datatable3(id INT, created_at ^changeset, updated_at ^changeset, deleted_at ^changeset NULL, <other fields>)


It is better, as others have written, because it preserves integrity constraints.


This is a rehash of all the things explained in the paper http://www.bailis.org/papers/feral-sigmod2015.pdf

TLDR: Not a good idea.


I get the relational bit. But can you expand on the Smalltalk one?


Smalltalk got a lot right very early on that got adopted in bits by everyone eventually. The idea of a fully interactive IDE, designing systems as distributed objects that exchange messages, and so on.

Unfortunately parceling it out and fudging it killed a great concept and we got stuck with corporate driven "OOP" that lives on in Java, Kubernetes, etc.

It's a wonder the people at PARC divined so much of great conceptual designs and other companies got to profit from bungled versions thereof.


Smalltalk is not perfect, it had some good ideas, but also some bad ones (in the sense of not being practical in most contexts) like the "image" mixing of code and data.


Far from perfect indeed. Yet it encapsulated so much of software architecture that is still relied upon and hasn't been advanced significantly since.


There were several great ideas at parc, indeed. I think the most powerful one goes unnoticed by most, which is how it was managed by Bob Taylor.


I did provide an alternative. Formally verify their software, making implausible for such error to occur. I have linked to a peer reviewed article that goes in-depth about such.


Consider applying for YC's Summer 2025 batch! Applications are open till May 13

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: