3 ms·
I don't see the problem. A true / false convention of 1 / 0 is not uncommon (nor is its inverse, but pick one) and so excel stores it as thus. Whether it displa
by NamTaf 12y ago
I don't see the problem. A true / false convention of 1 / 0 is not uncommon (nor is its inverse, but pick one) and so excel stores it as thus. Whether it displays as 'TRUE' / 'FALSE' or 1 / 0 is then determined by formatting, which is sensible.
The same would apply with dates. Datetimes are zero-indexed floating point numbers incrementing from 0/1/1900 [1]. Whether it's displayed as a date or number is simply a case of what format you select for the cell.
Formatting is then obviously specified as a flag in the metadata because by its nature, formatting is metadata not a value. If you implied formatting by the value stored, you open up all kinds of corner case issues (is "19/5/14", for example, an equation, date or string?).
I think the .xlsx format is really sensible here, and it's the applications that have woeful compatibility.
[1] Yes, 0th January is a date: https://en.wikipedia.org/wiki/January_0 https://en.wikipedia.org/wiki/January_0