News for hackers. Stuff that matters.
Re:Common data model mistakes made by startups by inopinatus on Saturday May 22, 2021 @07:28PM (#27251168)
Most order forms are snapshots of data at the instant of their lodgement, since they are sales contracts. It is a rookie blunder to link them relationally to master data for products and PII &c.

The record of an order is not intrinsically PII and thereby subject to rights of erasure. It may well be equally unlawful in some jurisdictions to irrevocably destroy it entire, it being necessary for accounting or tax audit, or even simply for mundane followup process, such as returns, that arise from actionable consumer rights. Ergo, such documents must fundamentally survive the erasure/redaction of any PII it does include.

Re:Common data model mistakes made by startups by jhgb on Saturday May 22, 2021 @10:06PM (#27251881)
> It is a rookie blunder to link them relationally to master data for products and PII &c.

Is it always? If that data is immutable, for example?

Re:Common data model mistakes made by startups by snowwrestler on Sunday May 23, 2021 @12:21AM (#27252433)
How are you going to satisfy data compliance, which may require the deletion of PII upon request or expiration, if your PII data is immutable?
Re:Common data model mistakes made by startups by atatatat on Sunday May 23, 2021 @02:12AM (#27252793)
Was just considering this when I came across your comment.

I'm hoping someone here can suggest a one-way audit-log audit-trail sort of solution, because I need this for the medical industry.

Re:Common data model mistakes made by startups by ranguna on Monday May 24, 2021 @02:55AM (#27261677)
I would say the structure of the records themselves can stay, but not the data itself.

If you have a user table, maybe you can just randomly hash the sensitive user data but keep the record.

Not 100% sure about this though, since you could probably derive the user with statistics like: if it's known that 1 person gets a specific disease every 10 years and you have an obfuscated record of a person connected with that disease, it's fairly straightforward to derive who that person is just through that connection.

Re:Common data model mistakes made by startups by jokull on Sunday May 23, 2021 @05:29AM (#27253620)
The way to do it is to have foreign keys, but instead of hard delete you scrub data in the columns.
Re:Common data model mistakes made by startups by snowwrestler on Sunday May 23, 2021 @10:40PM (#27260624)
Seems like if you can scrub data, it is mutable? Maybe I misunderstand what “immutable” means.
Re:Common data model mistakes made by startups by mvc on Sunday May 23, 2021 @03:32AM (#27253094)
How are you going to respond to a warranty claim if you've wrongly deleted the order data when a subject requests that you delete all PII you have about them?

https://www.adyen.com/blog/gdpr-what-it-means-for-customer-p...

Re:Common data model mistakes made by startups by snowwrestler on Sunday May 23, 2021 @10:55PM (#27260712)
You store the sales contract separately, which is what this whole subthread is about.

https://news.ycombinator.com/item?id=27251168

Re:Common data model mistakes made by startups by jhgb on Sunday May 23, 2021 @08:48AM (#27254649)
I'm not sure how this changes anything. Is your PII in the order forms/sales contracts mentioned above? If yes, you'll have to delete those as well anyway, right? If it's not, the order forms/sales contracts themselves don't have to be linked to something that may potentially get deleted.

Please note that by "immutable" I don't mean that data won't get deleted eventually, just that it won't be deleted until nothing needs it anymore (and until then won't be mutated either), so basically the same thing that languages like Haskell mean by "immutable". Then, once you don't need it (= it's not observable anymore), it could perhaps get archived or erased, whatever you prefer.

Re:Common data model mistakes made by startups by inopinatus on Sunday May 23, 2021 @09:48AM (#27254982)
Then it isn’t master data anymore; it’s just one field of a record of a commercial document. This is taking a long way around to the same point.

(Presumably no-one is trying to reference-count GC their RDBMS. If so, I wish them all the luck in the world.)

Re:Common data model mistakes made by startups by jhgb on Sunday May 23, 2021 @09:55AM (#27255030)
I'm not quite sure what "master data" means in English (a non-native language to me) but Wikipedia tells me that it's "data about the business entities that provide context for business transactions" (and lists examples that sound relevant for this situation to me). Based on that I'm inclined to think that this would qualify.