9 ms·
This is what I understood (s)he means Scenario: Laptop's price is initially $800 and then increases to $850 before dropping to $825 Design 1: with columns Am
by rehack 12y ago
This is what I understood (s)he means
Scenario:
Laptop's price is initially $800 and then increases to $850 before dropping to $825
Design 1: with columns Amount and Kind will just have a single row which will get modified with the latest value
Design 2: Will have 3 rows in the above case
Difference | Kind | Time stamp
800 | 'Laptop' | ts 1
+50 | 'Laptop' | ts 2
-25 | 'Laptop' | ts 3
So this latter design has 'undo' builtin
edit: formating
- ajuc 12y agoYes, that's what I've meant. This also gives you easy accountability (rows can have information like user_id, ip, timestamp).