DATEDIF is the Thrawn of Excel
Grand Admiral Thrawn is the best Star Wars character, and I won’t be taking questions.
If you’ve only watched the films you might not know him, which is sort of the point of this post. Thrawn comes from Timothy Zahn’s Heir to the Empire, published in 1991, back when there were no new films, nobody expected any, and Star Wars was mostly a box of old toys. Zahn wrote a sequel trilogy set five years after Return of the Jedi, and it went to number one on the New York Times list. A lot of people credit those three books with keeping Star Wars alive through the nineties.
Thrawn is a Chiss: blue skin, red eyes, the last Grand Admiral of a beaten Empire. Every other Imperial officer we’d met up to then was either Force-choked or about to be. Thrawn doesn’t shout and he doesn’t need a planet-killer. He studies a species’ art until he understands how they think, then beats them with it. He’s polite to his staff. He’ll lose a battle on purpose to learn something about the other side. When his own bodyguard finally kills him, at the end of the third book, his last words are “But… it was so artistically done.” I think about that line more than I should.
Disney bought Lucasfilm in 2012, and in 2014 everything outside the films and The Clone Wars was relabelled “Legends”, meaning not canon. Thrawn, along with thirty-odd years of books and comics, was officially something that hadn’t happened.
And then, slowly, they brought him back properly. He turned up in season three of Rebels in 2016, voiced by Lars Mikkelsen, and he was exactly right. Zahn got to write him again in a new Thrawn novel in 2017, then a stack more. In 2023 he walked on screen in live action in Ahsoka, Mikkelsen again, still in the white uniform. A Thrawn film was meant to come after that. As of this year it’s reportedly on the back burner. He waited more than 30 years to get from a paperback to live action, so I suppose he can wait a bit longer for the cinema.
I’ve been thinking about this because Excel has its own Thrawn, and it’s been sitting outside canon for even longer.
DATEDIF
DATEDIF works out the time between two dates in whole years, months or days. You’d think that would be a pretty central thing for a spreadsheet to do. Ages, tenure, how long a lease has been running, how many full months since a customer signed up.
It’s been in every version of Excel since the early nineties and it works fine, but Microsoft acts like it isn’t there. Type =DATED into a cell and autocomplete offers you nothing. Finish typing it and there’s no little tooltip telling you what goes in the brackets, which every other function gets. It’s not in the Insert Function dialog. By most accounts Excel 2000 is the only version whose built-in help ever mentioned it. Microsoft’s old Knowledge Base even had an article called “Undocumented Worksheet Function DATEDIF”,1 which is a funny thing to write about your own product. For years the only way you found out it existed was someone older at work showing you.
Microsoft does have a support page for it now, and the reason it gives for the function existing at all is that “Excel provides the DATEDIF function in order to support older workbooks from Lotus 1-2-3.”2 Lotus 1-2-3 was the spreadsheet everyone used before Excel. So DATEDIF is a Legends function, kept around because of a continuity that officially ended decades ago.
Google Sheets, for what it’s worth, just lists it in the function list like a normal function.
Free account
Read the rest with a free account.
The rest of the post is free for anyone with an account. We email you a link to log in, so there's no password to remember.