3 ms·
Intuitively, only store numbers in their natural dimension. The same thing regularly happens in finance where interest rates (1.5% ie 0.015) is often stored as
by cm2187 7y ago
Intuitively, only store numbers in their natural dimension. The same thing regularly happens in finance where interest rates (1.5% ie 0.015) is often stored as percent (1.5) in databases. And of course you never know what conventions people take, particularly in these days of super low interest rates. Then you have spreads which can either be stored in basis points (10bps), percent (0.1%) or natural (0.001). And currency of amounts, etc.
All table columns should also have unit in names, whether in charts, tables, database or variable names.
- TeMPOraL 7y ago> All table columns should also have unit in names, whether in charts, tables, database or variable names. Oh yes. That would mitigate a lot of stupidity. Imagine if math in programming and Excel had to have both a) always visible/known units, b) unit propagation and c) unit checks. So if A is seconds and B is kilograms, the compiler/spreadsheet wouldn't let you write C = A + B.
- selimthegrim 7y agoBlockpad (http://www.blockpad.net http://www.blockpad.net) is the answer to your prayers.
- jmnicolas 7y agoYet some people argue against strongly typed language ...
- Doctor_Fegg 7y ago> All table columns should also have unit in names Very similar to Hungarian notation: https://en.m.wikipedia.org/wiki/Hungarian_notation https://en.m.wikipedia.org/wiki/Hungarian_notation
- signa11 7y agoso then, 'paul' stands for a 'pointer to a unsigned long' :)