back to article The Eldritch Horror of Date Formatting is visited upon Tesco

Date formatting is one of the many banes of a programmer's existence. Pity, therefore, the Tesco customer presented with a date in the Julian format. Many developers experience a slight eyelid twitch when date formatting comes up. For sport, try mocking a greybeard about the two digits used to describe the year in older …

  1. Little Mouse

    Call me a snob, but...

    "Yup they was like a set you get 2 burgers 2 buns 2 cheeses slices and a sachet of the relish ."

    That food sounds so processed it would probably last forever...

    1. sabroni Silver badge

      Re: Call me a snob, but...

      You think counting things is processing?

      1. Teiwaz

        Re: Call me a snob, but...

        "4691 Irradiated Haggis!"

    2. Anonymous Coward
      Anonymous Coward

      Re: Call me a snob, but...

      For several decades I had a bottle of Perrier water on my desk. Its "use by" date was a year or so after I bought it in about 1988.

      Some time in 2014 I opened it and drank it.

      Amazingly, I survived.

      1. KBeee
        Joke

        Re: Call me a snob, but...

        "Filtered through a glacier for 1000 years" (use with 1 month)

        1. Arthur the cat Silver badge

          Re: Call me a snob, but...

          "Filtered through a glacier for 1000 years" (use with 1 month)

          Even better: "This salt was mined from salt deposits created as an inland sea dried up 300 million years ago. Best before 2050."

      2. AJB

        Re: Call me a snob, but...

        what prompted this sudden action after such a long period of delayed gratification? Code review passed first time?

      3. Doctor Syntax Silver badge

        Re: Call me a snob, but...

        1988. Wasn't that about the time when Perrier had benzene in it?

    3. Fungus Bob
      Trollface

      Re: Call me a snob, but...

      OK. you're a snob butt...

  2. The Oncoming Scorn Silver badge
    Paris Hilton

    Who reads those things anyway?

    Every woman that I have had the pleasure of knowing.

    1. sabroni Silver badge

      Re: Every woman that I have had the pleasure of knowing.

      What did she say?

      1. The Oncoming Scorn Silver badge
        Holmes

        Re: Every woman that I have had the pleasure of knowing.

        The soon to be ex-Mrs Scorn would designate any food 3 ms after the expiry date as not fit for human consumption.

        1. OssianScotland

          Re: Every woman that I have had the pleasure of knowing.

          You must be my Brother In Law!

      2. Anonymous Coward
        Happy

        Re: Every woman that I have had the pleasure of knowing.

        "Come on son! Supper's ready!"

        1. Ken Moorhouse Silver badge

          Re: Supper's ready!

          Those were the days when English ribs of beef were 47p per lb and Peek Frean's family assorted were 17.5p

        2. Anonymous Coward
          Anonymous Coward

          Re: Every woman that I have had the pleasure of knowing.

          "Walking across the sitting room, I turn the television on..."

    2. Aladdin Sane

      Re: Who reads those things anyway?

      How is your mum?

    3. Jedit Silver badge
      Trollface

      "Every woman that I have had the pleasure of knowing."

      There are faster ways to say "nobody", you know.

  3. vir

    I have heard from someone who works for a food company that the expiration or best by dates are set far earlier mostly so that customers aren't put off by how long processed food is actually good for.

    1. ibmalone

      According to an interesting programme on food safety a few years ago (possibly BBC), expiration dates are set by measuring how long it takes from contamination until the food is unsafe to eat. The premise is if it somehow gets contaminated before leaving the factory it shouldn't kill anyone.

      1. jrd

        Use By dates

        I remember one consumer/food programme where they measured bacteria in different foods kept in a fridge over a couple of weeks. Most foods were safe to eat several days after the "use by" dates. Amusingly, the bacteria count actually went down in some foods over time!

        1. Shadow Systems

          Re: Use By dates

          That's why the Use By date on a Twinkie just says "The Heat Death of the Universe".

          Of course there are fewer bacteria over time, the Twinkie keeps eating them!

          I'll get my coat, it's the one with the pockets full of softly glowing processed food. =-)P

      2. Anonymous Coward
        Anonymous Coward

        "The premise is if it somehow gets contaminated before leaving the factory it shouldn't kill anyone."

        .... ah, primitive societies that are yet to learn the benefits of the "chlorine wash"

        1. ShadowDragon8685

          Meh. Chlorine washing will do in a pinch, I suppose.

          Rather expose the MFer to so much hard ionizing radiation that not only does it come out the other end sterile, it comes out fully cooked!

          1. Anonymous Coward
            Boffin

            This was sort of tried in the 1980s.

            The food, including fruits; was exposed to strong UV light to kill the bacteria.

            Since UV is a radiation type, and the emitter could cause some minor harm to humans if exposed long enough, HSE meant a radiation warning sticker on the machine.

            Radiation sticker = NUCLEAR POWER to the brain dead, and so the hysteria started.

            I am still amazed CD players made it, as the laser is also a radiation source, so there is a similar (if smaller) sticker on all CD/DVD players.

            1. Claverhouse Silver badge

              Re: This was sort of tried in the 1980s.

              The difference would be that CDs are optional, whilst eating is not.

        2. Anonymous Coward
          Anonymous Coward

          The joys of civilization

          Yeah, why bother killing people with expired food when you can do it with chlorine?

        3. ibmalone

          Chlorine washing soup is a bit tricky...

          1. Fungus Bob

            It'll evaporate.

            And if you're wondering if I'm referring to the soup or the chlorine. Yes, I am...

  4. Anonymous Coward
    Anonymous Coward

    Dates? Don't talk to me about dates...

    I've got a pain all the way down the left side of my calendar.

    I've just been having (very limited) amounts of fun with a customer, who have a system maintained by a third-party supplier.

    Said supplier seems to have extremely limited technical capabilities.

    First, they complained about the fact that we use the date format "YYYY-MM-DD" for data import/exports, and asked if we'd be willing to change to DD/MM/YYYY. So I politely explained that this would be a bad idea, as there's a risk that it'll get confused for MM/DD/YYYY.

    Then, we came to the CSV file that's going to be delivered as part of the process. Things were already a bit strange as they wanted it pipe-delimited rather than comma delimited, but things took an even stranger turn when they flagged up the fact that only some fields were quoted.

    Cue an even politer explanation about the fact that we're using the standard platform CSV exporter, and it doesn't quote fields unless it needs to. And I pointed at the CSV RFC, which explicitly states that fields only need to be quoted if they contain certain characters.

    "Oh, it's ok", they eventually exclaimed. "We'll just delete any double-quotes from each line before we process it. And as we asked, you're sending the file with pipe delimiters, so we don't need to worry about escaping commas".

    It's rare for me to be literally speechless, but it did take several seconds before I felt safe to respond...

    1. Steve Foster
      Joke

      Re: Dates? Don't talk to me about dates...

      Sounds a bit like they're taking the psv...

    2. Shadow Systems

      Re: Dates? Don't talk to me about dates...

      *Hands you a pint & taps brims in toast*

      Here's to using the proper YYYY.MM.DD format.

      It auto sorts itself properly, it's hard to get the digits mixed up, & it makes everything easier.

      Everyone whom uses a different format is an utter poopyhead. =-)P

      /S

      1. Youngone Silver badge

        Re: Dates? Don't talk to me about dates...

        utter poopyhead

        Steady on! Mind your language.

      2. DWRandolph

        Re: Dates? Don't talk to me about dates...

        Been using CCYY-MM-DD ever since 1970's. A mortgage company dealing with 30 year loans had to worry about that CC rollover!

        And a proper HH:MM 24 hours clock, none of that futzing with AM or PM fizz (time zones are bad enough).

      3. petef

        Re: Dates? Don't talk to me about dates...

        The proper format is YYYY-MM-DD if you follow the international standard ISO8601 extended format. Using a period instead of hyphen would give some of the same benefits but it is not standard.

      4. ShadowDragon8685

        Re: Dates? Don't talk to me about dates...

        MONTH-DD-YYYY begs to differ on all points save computer auto-sortability. But changing your filing system to suit your computers is rather like changing the postal service area to make another post office handle it because the postal carrier's walking too far, rather than, say, hiring additional carriers.

        1. sawatts

          Re: Dates? Don't talk to me about dates...

          tens-units-hundreds?

          1. phuzz Silver badge

            Re: Dates? Don't talk to me about dates...

            AKA 'middle-endian'.

            There must be something about Americans that makes them want to deliberately do things the arse-backwards way. See also: using non-metric units long after the rest of the world has moved on, insisting that a constitution from two hundred years ago is still perfectly attuned for modern life, etc.

            1. Red Ted
              FAIL

              Re: Dates? Don't talk to me about dates...

              The most frustrating thing about the American's use of the imperial system is them not using all of it.

              One of the important points of the imperial system is there a unit bigger or smaller that you can go to if the numbers start getting too big or small. Take length, you start at inches, then move on to feet, yards, chains and miles. With weight you have ounces, pounds, stone, hundred weight and tons.

              So why do they insist on specifying the weight of a car or locomotive in pounds?!

              1. Anonymous Coward
                Anonymous Coward

                Re: Dates? Don't talk to me about dates...

                "So why do they insist on specifying the weight of a car or locomotive in pounds?!"

                Because deep down they know that they really want to use kilograms like proper grown-ups, but are just too scared to admit it to some of the MAGA-hat-wearing types out there?

                (Arguably none of us gets it quite right: we perhaps ought to use Mg for quite heavy\\\\\massive things [1], and Mm for distances on the far side of the Earth, but we never do!)

                [1] Quite heavy, as in the order of magnitude of 1 m³ of water (that always amuses me to think of, but I'd much rather that didn't fall on my head all at once).

                1. Anonymous Coward
                  Anonymous Coward

                  Re: really want to use kilograms like proper grown-ups

                  Proper grown ups? The ones who find the maths in imperial measurements too complex?

              2. John Brown (no body) Silver badge

                Re: Dates? Don't talk to me about dates...

                Having watched a fair number of US TV shows, especially documentaries, at least some of it seems to be sensationalism. Bigger numbers are more impressive and/or scary.

              3. Carpet Deal 'em
                Boffin

                Re: Dates? Don't talk to me about dates...

                Point of order: the US doesn't use the imperial system, but rather its own that agrees with it in most respects. The most obvious difference is liquid measures: the imperial gallon is 160 imperial ounces while the US gallon is 128 US ounces.

    3. Doctor Syntax Silver badge

      Re: Dates? Don't talk to me about dates...

      "Things were already a bit strange as they wanted it pipe-delimited rather than comma delimited"

      Did they also want a pipe at the end of each line? It could be they're importing into Informix as that's the standard import/export format.

      1. Anonymous Coward
        Anonymous Coward

        Re: Dates? Don't talk to me about dates...

        Nah. The fellow likely works in the publishing industry (newsprint), so they are converting from whatever SQL DB to Progress OpenEdge. Leaving the vendor name out because it changes every three years anyway. It uses a modified 4GL they call ABL (Advanced Business Language or some such). And they love that pipe separator, just like Informix. That said, the record (line) separator can be specified as either a pure LF or CR+LF combo, instead of ending with a pipe + LF.

        Fun fact about Progress databases - the data fields are not fixed. If the table definition says that this particular field is up to 27 characters, but you want to put 34 characters in there - Just Do It! However, you'll have to remember to tell Progress that the field is now longer, otherwise some of your data will not show for you.

        The Progress corporation also purchased Telerik (ASP.NET + JavaScript enabled components) a few years back, then proceeded to update their website with those components. It was painfully slow at first, but, over time, it has become much better.

        1. Doctor Syntax Silver badge

          Re: Dates? Don't talk to me about dates...

          I had a client about Y2K time in printing. They too used an application that used Progress IIRC. Can't remember the vendor name. Another client, same industry, also had an industry-specific application that did use Informix on SCO. From the perspective of most sales and stock operations they do things a bit peculiarly there. The Informix based one had an interesting quirk. They were, I think, supposed to ship with a run-time only installation but they had ?accidentally left in one of the development applications - sformbuld IIRC. But as all the non-4GL development applications are all the same executable, just link to the relevant names and, ooh, look, a full Informix development suit.

          1. Doctor Syntax Silver badge

            Re: Dates? Don't talk to me about dates...

            Suite, dammit!

      2. ChrisElvidge

        Re: Dates? Don't talk to me about dates...

        Standard output from YAD forms, too.

    4. Justin Clift

      Re: Dates? Don't talk to me about dates...

      > platform CSV exporter

      Errr.... which platform? Almost every CSV exporter is custom build.

      Also note, "the CSV RFC" is not as clear cut as you're making it out to be.

      It was only an attempt to draw a sand in the line as there were so many incompatible implementations already floating around.

      That RFC does cover most of the common stuff, but doesn't cover a few key areas (null values? binary encoding? unicode bom? field names?).

      There have been some follow up concept docs started since, but nothing has become a new & improved RFC yet either.

      1. Joe W Silver badge

        Re: Dates? Don't talk to me about dates...

        The commata... Great fun in countries that use it as a decimal separator. The Tektronix oscilloscope we had in our lab could export to csv files, (well, some windows program talking to it over USB could), but would use the locale to choose a decimal separator. Hilarious. Not. (at that time).

        1. Anonymous Coward
          Anonymous Coward

          Re: Dates? Don't talk to me about dates...

          "The commata... Great fun in countries that use it as a decimal separator."

          Altenatively there's the double take when getting a hotel bill after a 10-day business trip in India before you remember that they add commas at thousands and 100-thousands ("lahkts") so the total with two commas is actually 10x smaller than your mind has initially registetered!

        2. Schultz
          Boffin

          Re: use the locale to choose a decimal separator

          Techtronix is in good company: Labview, a 'systems engineering software' commonly used for the control of scientific equipment takes the locale from the host computer to choose the decimal separator. In a place like Germany, half of the computers will become incompatible with your carefully grown jumble of data acquisition and analysis programs, simply because you have a mix of German and English locales in the academic environment.

          Just one of the many nightmares caused by those greedy bastards at National Instruments / Labview.

        3. Mike 137 Silver badge

          Re: Dates? Don't talk to me about dates...

          Keysight (HP rebranded) now use comma separators between all elements of both date and time returned by their measurement gear. As these instruments comply with SCPI (which uses commas to separate multiple readings returned from a single command) this renders it impossible to use the data and time stamps in CSV output.

      2. Anonymous Coward
        Anonymous Coward

        Re: Dates? Don't talk to me about dates...

        > Errr.... which platform? Almost every CSV exporter is custom build.

        For better or worse, ours is pretty much a straight call to PHP's built-in library (which effectively boils down to "fputcsv(fp, array)").

        Language-haters incoming in 3... 2... 1...

        > Also note, "the CSV RFC" is not as clear cut as you're making it out to be.

        This is true. The RFC is an attempt to formalise something which is very loosely defined and prone to abuse/hacks. There's no shortage of implementations where someone's just jammed a comma between the fields in each line and hoped for the best.

        But at the same time, we're generating the file using an industry standard implementation which has been tried and tested by millions across the world.

        And from the conversations we had around transmitting the data in other formats (e.g. JSON, XML), I strongly get the impression that whatever the solution would have been, they would have manually hacked a parser together to brute-force extract the fields.

        From this, the two main scenarios are that they're either running on some hideously restricted platform, or that their technical capabilities are seriously lacking. Or possibly both...

        1. Anonymous Coward
          Anonymous Coward

          Re: Dates? Don't talk to me about dates...

          > But at the same time, we're generating the file using an industry standard implementation which has been tried and tested by millions across the world.

          *cough*. MS would make the same claim for their software (Excel output, etc). And probably be just as accurate, yet just as incompatible with other implementations. ;)

    5. Ken Moorhouse Silver badge

      Re: literally speechless + escaping commas

      literally speechless

      Is that due to them deleting inverted commas when found?

      escaping commas

      When captured, can they expect a long sentence?

    6. really_adf

      Re: Dates? Don't talk to me about dates...

      ... "Oh, it's ok", they eventually exclaimed. "We'll just delete any double-quotes from each line before we process it. And as we asked, you're sending the file with pipe delimiters, so we don't need to worry about escaping commas".

      This story resonates with my own experience. Things like this seem to be increasingly common. I've gone past getting mad, now it just makes me sad...

    7. Amentheist
      Happy

      Re: Dates? Don't talk to me about dates...

      Certain UK address db comes like that (unquoted and pipe delimited) but in fairness no address will ever contain a pipe character so it does save a lot of space when in text form.

      1. Graham Cobb Silver badge

        Re: Dates? Don't talk to me about dates...

        no address will ever contain a pipe character

        Ooh, ooh, ooh - sounds like a challenge!

        My hobby is now going to be inserting a | at the end of my house name every time I type it into a web site. I wonder how many will accept it? And how long before it starts appearing in address databases?

        1. Amentheist
          Joke

          Re: Dates? Don't talk to me about dates...

          Pipe? Go all the way and do \ (but as a final character).

          Actually looking through that db wherever there are notes they're enclosed in {} so you basically have to xkdc-it.

    8. Scott 53
      Facepalm

      Re: Dates? Don't talk to me about dates...

      I remember dealing with a data analyst at a major insurance company. Having been asked for a CSV, he sent me an Excel spreadsheet (.xls format). On being reminded, he sent me a .csv. Oddly enough, this failed to load, and when I looked at the file in a text editor it became apparent that what the "analyst" had done was change the file extension of the original spreadsheet. I had a bit of a pause before responding, mainly to work out how I was going to start the ensuing conversation.

  5. MJB7
    Thumb Up

    Well done Tesco's

    Did El Reg offer the PR hack a job?

    1. Doctor Syntax Silver badge

      Re: Well done Tesco's

      At least they didn't give a tart reply.

    2. A K Stiles
      Coat

      Re: Well done Tesco's ...

      ...what? Well done Tesco's burgers? Well done Tesco's finest steak? Well done Tesco's value lasagne?

      I know they're technically a grocer, but they don't need the grocer's apostrophe!

      I know, I'm leaving now anyway!

      1. Dave559 Silver badge

        Re: Well done Tesco's ...

        If the supermarkets started by Mr Sainsbury are (indeed) "Sainsbury's" supermarkets, then by extension, Mr Cohen's supermarkets can be "Tesco's".

        It's a possessive, not a plural.

    3. Nick Kew
      Thumb Up

      Re: Well done Tesco

      Well done indeed. Groanworthy in a good way. How did someone with a sense of humour get into corporate PR, and what kind of Red Tape let it through? Congratulations to Tesco for allowing that through without at the same time subjecting the world to a full Bozzersworth of toecurling gaffes.

  6. Charlie Clark Silver badge

    I hate to be a spoilsport but…

    … this is why we have things like norms (BSI/EN) to which you can point the supplier and say: "like that". Imagine all the fun you can have with unlimited liability if something like this went stateside, someone consumes said product unable to understand the best before date and sues over food-poisoning. Actually, I bet this has already been tried. Many times. Many, many times.

    Of course, what's slightly worrying is that the ISO spec is behind a paywall. Though not quite as worrying as that the supplier maybe running a computer system so old that it needs to save the odd byte!

    1. SloppyJesse
      Joke

      Re: I hate to be a spoilsport but…

      ... "Though not quite as worrying as that the supplier maybe running a computer system so old that it needs to save the odd byte!"

      Printing less digits saves ink. You've seen the price of ink, right?

      1. theblackhand

        Re: I hate to be a spoilsport but…

        You realise the ink is significantly more expensive than the contents of the package the supplier considers good...

      2. Nick Kew
        Headmaster

        Re: I hate to be a spoilsport but…

        Every little helps.[1]

        But please, not at the expense of our language. It's fewer digits.

        [1] Tesco's advertising catchphrase - for the benefit of international commentards.

        1. Charlie Clark Silver badge
          Mushroom

          Re: I hate to be a spoilsport but…

          I think we should be getting ready to accept the equivalence of less/fewer. It's certainly not high up on my list of pedantic peeves:

          • creating new verbs from nouns when more concise forms already exist: incentivise instead of encourage, onboarding vs. introducing, etc.
          • intransitive verbs used with objects without prepositions
          • US-EN style dates with numeric months
          .But while we're talking about fewer versus less: a pox on all those who insist on treating data a plural: fewer data is just wrong!

          1. jeffdyer

            Re: I hate to be a spoilsport but…

            It has nothing to do with the subject being plural, it's whether it can be counted as in discrete individual items or has to be measured as in a quantity.

            Fewer people, less time. Fewer problems, less fun. Exactly equivalent to "number of" and "amount of".

            HTH.

            1. Charlie Clark Silver badge

              Re: I hate to be a spoilsport but…

              I do understand the difference and can use them both correctly. But my "internal parser" doesn't seem to care that much when I hear or read them used incorrectly (less seems invariably to replace fewer), after all we don't see to care when talking about more of some thing. This might have something to do with that the distinction isn't made in the other languages I speak.

              Like I said, there are other linguistic trends that I fight more objectionable. But each to their own.

              1. Nick Kew
                Headmaster

                Re: I hate to be a spoilsport but…

                To be honest, it's not really high on my list of pet peeves, either. It's not the level of illiteracy that inclines me to dismiss a poster as hard-of-thinking.

                I just couldn't resist applying the Tesco slogan to a post about saving a digit. Having done so, how could I not then also bemoan the saving of a single letter in a grammatical error which might, in the humorous context, have been entirely intentional? Elsewhere in this thread, I pose a question to which I know the answer perfectly well, only to see it explained to me (I expect it would be called "mansplaining" if the posters katrinab and myself had been reversed).

            2. I ain't Spartacus Gold badge

              Re: I hate to be a spoilsport but…

              The less / fewer thing is all very well, but where's the opposite gone? We're already using more for both jobs - and have the saying "more or less". But there's no more or fewer...

              Which leads me to the opinion that fewer is pointless. Why do we have this distinction, and does losing it lead to ambiguity? After all, we say more people, more time more problems, more fun.

              1. Nick Kew
                Coat

                Re: I hate to be a spoilsport but…

                The word more is simply overloaded with manyer meanings than its opposites.

              2. jeffdyer

                Re: I hate to be a spoilsport but…

                Good point.

                What I hate is when I hear "amount of people" as if crowds can somehow be chopped into bits and weighed.

                1. Jimmy2Cows Silver badge
                  Devil

                  Re: I hate to be a spoilsport but…

                  Well... strictly speaking, they can be.

                  Gets messy, though.

    2. John Brown (no body) Silver badge

      Re: I hate to be a spoilsport but…

      "Imagine all the fun you can have with unlimited liability if something like this went stateside, someone consumes said product unable to understand the best before date and sues over food-poisoning. Actually, I bet this has already been tried. Many times. Many, many times."

      Tesco do make the point that this date is purely a manufactures internal checking system on packet inside the main packaging and that the Best Before date intended for the customer is printed on the outer packaging exactly where it's legally supposed to be. I don't think there is a requirement for a Best Before date on individual packets within these "meal kits" because the outer packaging must have the Best Before date for the shortest lived ingredient/item.

  7. Anonymous Coward
    Anonymous Coward

    Asking the real questions here, why was there only one sachet of relish?

    1. Dan 55 Silver badge

      Because two sachets half the size would clearly be too much plastic whereas one double-sized sachet shows how the supermarket cares for the environment, obvs.

      1. Anonymous Coward
        Anonymous Coward

        Sachet fuss about relish.

        1. Ken Moorhouse Silver badge

          Sachet fuss about relish.

          Some say that Mr Stock had a bit of a sauce to make such a complaint.

  8. cornetman Silver badge
    WTF?

    Over here in Canada, it is very common to still see packing dates with a 2 digit year.

    Pretty inexcusable.

    Anyone who has spent much time with databases and import/export of data knows what a complete headache date formats are.

    Adding Julian dates to that unholy mixture is just taking the p*ss.

    1. ibmalone

      If it is in the cupboard long enough that a two digit year becomes ambiguous then it's either passed the best before or never will.

      1. katrinab Silver badge

        My stuff from the Chinese supermarket sometimes has bbe dates in the yyyymmdd format.

        So if was marked 190620, is that good for almost a year, or did it expire last week?

        1. jeffdyer

          190620 isn't in the yyyymmdd format.....

    2. Anonymous Coward
      Anonymous Coward

      How in the hell is a two digit year inadequate for a packing date? You stocking a fallout shelter you plan to hand down to your great-great-grandchildren?

      1. cornetman Silver badge

        Well, duh.

        The point is that a 2 digit year makes the format ambiguous.

        Knowing what the year is, is not the point.

        But if you can't determine the format of the date unambiguously, you can't know which is the day and which is the month reliably.

        Since the year is 2018, then assuming that you know the can of food was bought this year, then you can probably determine that 18 is the year part. However, canned food can have a very long life indeed.

        For the cost of just putting an extra couple of digits for the year, that ambiguity is reduced immensely.

        1. Jamie Jones Silver badge

          Pssst *2019*

      2. Ken Moorhouse Silver badge

        Re: You stocking a fallout shelter you plan to hand down to your great-great-grandchildren?

        Actually, no. Just planning for a No-Deal Brexit.

  9. chivo243 Silver badge
    Pint

    best way so far?

    My boss insists that anything going into the Digital Archive to be YYYYMMDD, come to think of it, the RFC's I submit come back with that date format in the document name to be filed.

    1. ibmalone

      Re: best way so far?

      YYYYMMDD is allowed by ISO 8601, and has the pleasant property of numerical sort order being the same as date sort order. Although the hyphenated format YYYY-MM-DD is more agreeable to people and still lexically sortable until 10k AD rolls around.

      What I hadn't taken note of previously is that ISO 8601 also includes an ordinal date representation, YYYY-DDD. (Must be three digits, otherwise it would be ambiguous with YYYY-MM.)

      1. Anonymous Coward
        Anonymous Coward

        Re: best way so far?

        That ordinal date representation probably causes problems during leap years. I wonder how many systems assume DDD <= 365 because the programmer didn't consider that. Plus while I imagine the ISO standard specifies it, and I assume Jan. 1 is 001, there's room for ambiguity there as well if the programmer doesn't have that ISO standard in hand...

        1. petef

          Re: best way so far?

          One of the drivers behind ISO8601 formats such as YYYY-MM-DD and YYYY-DDD is that they are precisely defined in the standard and not in prior use. So they are fairly unambiguous. Users of the formats will know that MM ranges from 01 to 12 and DDD from 001 to 366.

          Markus Kuhn has summarized ISO8601 though nowadays there is also Wikipedia.

          1. Ozumo

            Re: best way so far?

            Surely "fairly unambiguous" = "ambiguous"?

            1. ibmalone

              Re: best way so far?

              At the end of the day they could all just be arbitrary squiggles.

          2. Dave559 Silver badge

            Re: best way so far?

            Hehe, good to know that Markus Kuhn's website is still around. He's one of the names I recognise from usenet, umm, mumble, years ago...

            (Funny/sad how not so many names from usenet necessarily seem to have transferred to other social networks, assuming similar ongoing interests, although I think there are a couple of names here in The Register comments that I recognise. (Of course, many of us, then and now, go under at least semi-pseudonyms...))

    2. Simon Harris

      Re: best way so far?

      "My boss insists that anything going into the Digital Archive to be YYYYMMDD"

      At my previous job documents had to have the month spelled out in letters and 4 digit years so there could be no date order misunderstanding.

      1. Chris Leeson

        Re: best way so far?

        Ah - standard VMS Date/Time format. The best way to handle dates. Completely unambiguous.

        (And before people start on about alpha sorts, most of the time my dates are in a database, in a date/time datatype. The only time you need to do an alpha sort is when you express the date outside the datatype (like embedding it in file names, for example))

      2. Dan 55 Silver badge

        Re: best way so far?

        At my previous job documents had to have the month spelled out in letters and 4 digit years so there could be no date order misunderstanding.

        Doesn't work for localisation or sorting if the sort routine doesn't know it's a month.

      3. Primus Secundus Tertius

        Re: best way so far?

        When I worked for the London office of a US company, I always wrote dates in documents and emails as dd-mmm-yyyy. So today is 26-Jun-2019.

        But for databases, 20190626 is much better.

        Excel stores dates as integers, but displays them as dates, if you mark the cell as date format. So 20140 becomes 20/02/1955. The Tesco claim of Julian date is nonsense: a Julian date is a pure integer, not some combination of year and day-number.

        1. RancidOrange

          Re: best way so far?

          From the Internet, so it must be true:

          What is Julian date example?

          A Julian date is sometimes used to refer to a date format that is a combination of the current year and the number of days since the beginning of the year. For example, January 1, 2007 is represented as 2007001 and December 31, 2007 is represented as 2007365.

  10. Dan 55 Silver badge
    WTF?

    Julian dates WTF

    Julian date epoch is in 4714 BC, so the relish either went off sometime in 4659 BC after 20140 days or will go off in the 160th century after 20140 years, neither of which bodes well (someone's going to correct me on both dates).

    1. ibmalone

      Re: Julian dates WTF

      According to The Wiki* the term is also used in the food industry** to refer to the ordinal date format that the article mentions.

      * citation needed

      ** by who?

      https://www.dm.usda.gov/procurement/toolkit/docs/calendar.pdf

    2. matt 83

      Re: Julian dates WTF

      As mentioned in the article, Julian date format != Julian calendar.

      Is your eye starting to twitch? Mine is.

      1. ibmalone

        Re: Julian dates WTF

        No, it's worse than that. https://en.wikipedia.org/wiki/Julian_day

        "The Julian day number is based on the Julian Period proposed by Joseph Scaliger, a classical scholar, in 1583, at the time of the Gregorian calendar reform, as it is the least common multiple of three calendar cycles used with the Julian calendar:

        " 15 (indiction cycle) × 19 (Metonic cycle) × 28 (Solar cycle) = 7980 years"

        So it can mean either the number of days since the epoch (to astronomers and historians) or the number of the day in the year (to people who make ready meals).

        1. Dan 55 Silver badge

          Re: Julian dates WTF

          So it seems Julian date != Julian day != Julian calendar. Here I was happy in my ignorance that the Julian calendar ended in the 16th-18th century depending on the country.

          Yes, my eye has started to twitch, as has other parts of the body, but that started happening years ago such is IT.

          1. Vincent Ballard
            Coat

            Re: Julian dates WTF

            18th? Try 20th. There's a reason that the anniversary of the October Revolution of 1917 is in November.

            1. Anonymous Coward
              Anonymous Coward

              Re: Julian dates WTF

              The Orthodox Church still uses it. Never adopt something correct if it happens to be made by someone you don't agree with for totally different reasons...

            2. Anonymous Coward
              Anonymous Coward

              Re: Julian dates WTF

              "There's a reason that the anniversary of the October Revolution of 1917 is in November."

              Also why the UK tax/financial year starts on April 6.

              ... origanally years started on March 25 (Lady day - still used for many agricultural rent payments) because the year was "Anno Domini" - i.e. years marked by the presence of Jesus on earth - and if he was born on Dec 25 then he was "present in utero" 9 months earlier on March 25). When the UK switched from Julian to Gregorian calendars (due to the drift in seasons until the Gregorian calendar introduced the additional leap year corrections every 100 and 400 years) which resulted in 11 days being dropped from the calendar to correct dates led to popular revolt over the idea that the government were doing it to get taxes earlier meant that the date of taxes being due was moved back by 11 days - hence the oddity of April 5/6 is the boundary of UK taxes years.

              N.b. for IT angle ... I remember talking to someone who worked for a big software house when they were starting to considere Y2K issues and when they thought they'd got this all under control someone raised an issue that "isn't there something special about leap years when the year is divisible by 100" as no-one had considered this .... fortunately the rule drops leap years when the year is divisible by 100 unless it is also divisble by 400 ... so 2000 was still a leap year.

            3. Nick Kew
              Facepalm

              While you're there ...

              Remind us when Oktoberfest happens?

              And why do we have seventh, eighth, ninth and tenth months preceded by eight unnumbered months in our calendar? No wonder I missed my appointment with Life!

              1. katrinab Silver badge

                Re: While you're there ...

                Julius Augustus Cæsar named two months after himself and added two new months to the beginning of the year.

                1. ibmalone

                  Re: While you're there ...

                  The Julian calendar reform didn't add any months; there were already 12 by the time that Julius Caesar changed the calendar. Arguably they removed one, since an intercalary month was removed. The reason for the numbering of the second half of Roman month names being apparently regular but out of whack (Quintilis, Sextilis, Sept through to Dec- ember) isn't really known. Later Romans believed there were originally only ten, their supposed "calendar of Romulus" lacks January and February, but modern historians doubt it, there may never have been ten. For a while those two months were at the end of the year and probably moved to the start about 100 years before Julius.

                  By the time of the Julian reform the Roman calendar was mad. Between 355 and 378 days in a year, depending on the decrees of the pontifices (there's a reason the term sounds familiar), a decision theoretically made to keep the seasons in line, but usually practically made to influence political terms of office. Is it the nones, the ides or the kalends of the month?

                  https://en.wikipedia.org/wiki/Julian_calendar is a fascinating insight into classical era astronomy, politics and international relations with a bit of date accounting tossed in on top. But anyone who thinks DD/MM/YYYY versus MM/DD/YYYY is an eldritch horror had better not read it.

              2. DCdave
                Pint

                Re: While you're there ...

                The Oktoberfest is partly in September because of unreliable weather, not because of the calendar type.

          2. Brewster's Angle Grinder Silver badge

            Re: Julian dates WTF

            You're not wrong. Section 1.252 of the Explanatory Supplement to the Astronomical Almanac defines a Julian Date to be a Julian Day Number plus a fractional time of day; e.g. 20145.5. Even, Meeus, bless his cotton socks, grudgingly admits 'In many books we read "Julian Date" instead of Julian Day.'

            If you'd asked me before I'd read this. I'd've said it was either a count of terrestrial rotations from the Julian epoch or a calendar date expressed in the Julian calendar. But the adjective Julian gets liberally used in astronomy.

            1. Aladdin Sane

              Re: Julian dates WTF

              In 40k, didn't the Ecclesiastarchy divide the Terran year into 1000 equal parts?

            2. DropBear
              Trollface

              Re: Julian dates WTF

              Reminds me of that scene of Indy almost falling to his death due to ambiguities related to the spelling of the name of God. I can kinda imagine an alternate scene where dates are involved instead, and upon realising this Indy flat out goes "oh HELL no, screw this!" turns around and just walks out...

    3. petef

      Re: Julian dates WTF

      Julian day number was well understood by astronomers and other savvy time watchers but then IBM in the 1970s IIRC started to use Julian day to mean ordinal day of the year. There is no connection to Julius Scaliger or Caesar.

      1. STOP_FORTH
        Trollface

        Re: Julian dates WTF

        Thanks, I wondered where this aberrant version came from. Probably best not to even mention Modified Julian Date. It is a very large number of days and half a day out from the original Julian Date. I think some people may be using MJD but calling it Julian Date.

        All very satisfying - if you are not a professional programmer.

  11. Simon Harris
    Coat

    The US military has made use of [ordinal dates]...

    While the upper hierarchy of the Roman Catholic Church make use of Cardinal dates.

    Mine's the one with a copy of the 95 Theses in the pocket ---->

    1. Anonymous Coward
      Anonymous Coward

      Re: The US military has made use of [ordinal dates]...

      Remember guys, you can date the Cardinals, but you can't marry them.

      1. Cardinal

        Re: The US military has made use of [ordinal dates]...

        "Remember guys, you can date the Cardinals,"

        It's a bloody lie!!!

        1. Forum McForumface

          Re: The US military has made use of [ordinal dates]...

          Nope - cut’em in half and count the rings.

      2. Ken Shabby

        Re: The US military has made use of [ordinal dates]...

        Novice mistake

    2. Aladdin Sane

      Re: The US military has made use of [ordinal dates]...

      No need to pontificate.

  12. mark l 2 Silver badge

    Best before dates are only useful to the supermarkets as a way of ensuring they get rid of their old stock first so it makes sense for them to use a code that is not meant for the consumer. For a consumer a best before date is misleading and can cause people to throw away food that is perfectly edible because the best before date has been reached and really should be removed from packaging.

    A use by date is different and should be adhered to more strictly, although with a bit of common sense food can still be eaten passed its use by date. Give it a visual and smell check first to see if there is any signs of it going bad. After all the human race has managed for millennia without pre-packed food with best before and use by dates on it, without everyone getting food poisoning.

    1. Dan 55 Silver badge

      After all the human race has managed for millennia without pre-packed food with best before and use by dates on it, without everyone getting food poisoning.

      Well, the race as a whole survived, but some people you didn't know died.

    2. Cardinal

      @mark l 2

      "Give it a visual and smell check first to see if there is any signs of it going bad."

      And they try to tell you that colds aren't fatal eh?

    3. katrinab Silver badge

      The death rate has dropped considerably since we adopted this along with other public health measures.

      1. jeffdyer

        Right. Throw all modern medicine and other benefits away, it's just the "Use By" date on food packaging that's increased life expectancy....

        1. Doctor Syntax Silver badge

          "Throw all modern medicine and other benefits away"

          Especially when they reach their "Use by" date.

  13. Henry Wertz 1 Gold badge

    Well, OK

    Well, OK -- I thought this date format was pretty dumb, until right at the end where they pointed out there was a "best used by" date in a more normal format on the package as well. Fair enough.

    1. Malcolm Weir Silver badge

      Re: Well, OK

      Quite. And while poking fun at supermarket procedures is fun and all, it's worth noting that the manufacturing code on integrated circuits and the line often uses a year-week or week-year format.

      In test applications (particular military tests), we often use ordinal/Julian dates because tests often run across day boundaries but rarely across multiple year boundaries, and who wants to fuss with how many days February has?

      In fact, IRIG-200 (defining IRIG-B, etc) uses the phrase "time of year" to refer to formats having a day component. And it's typically encoded in BCD, so standard-issue humans can see at a glance what the timestamps represent.

      However, that's on the slow way out, being replaced by the IEEE 1588 format, which is its own level of pain as it's a tuple of (seconds since epoch, nanoseconds), usually encoded as a pair of unsigned integers, with the seconds supposedly a 48 bit quantity (nanoseconds is 32 bit). OBVIOUSLY people muck around with this, making the seconds signed and 32 bit if it suits them, because why not!

  14. TomPhan

    It's pretty common for any multi item product to have a single date in customer readable format on the outside of the box, and each individual item to have a supplier readable date.

    So as soon as you throw away the box to get everything into the pantry you're lost.

  15. steelpillow Silver badge
    Joke

    Happy punsters

    "We're sorry if any of our customers got in a pickle about this and we have relished the chance to put the record straight."

    And if you ever complain again we will spam you with even worse puns until 99365

    Hang on, isn't punsters a popular brand of pies?

  16. Anonymous Coward
    Anonymous Coward

    BBE stands for...

    ...Brutal Beginning of Ebola

  17. Planetary Paul
    Megaphone

    XKCD

    XKCD explains it all here: http://xkcd.com/1179/

    1. Ken Shabby

      Re: XKCD

      Teradata

      (YEAR - 1900) * 10000 + (MONTH * 100) + DAY

  18. ibmalone

    Tesco, dates, social media

    This episode has jogged a memory from last year, when Tesco did rather less well on dates and twitter.

    Cast your mind back to 1st March 2018; this was the last day that paper £10 Bank of England notes could be used. Having a small amount of cash at home for emergencies I realised it needed to be spent. So, that afternoon used it to top up a travel card and attempted to buy some groceries. You can see where this is going. Tesco metro staff adamant that "no longer used after 1st March" means no longer used on 1st March. So I went and spent the money at Sainsbury's instead.

    Slightly irritated (and after checking) I complained on Twitter, and rather than pickle puns got an un-amusing, "As of that date, they are being withdrawn from circulation. All our colleagues at manned checkouts are aware that they should not accept the notes from 1 March." It appears the entire company misunderstood the BoE guidance and stopped taking them a day early.

    Of course "legal tender" is a strictly limited concept, and shops can choose not to accept currency pretty much arbitrarily; it's why your local corner shop is in its rights to put up "No £50 note's" signs. But I thought it was a bit poor that a. their twitter team couldn't simply say "sorry about that", b. whoever they put in charge of the phase-out failed to check the most basic thing about their task. Fortunately one of the up-sides of living in a fairly big city is having some choice over the level, or at least type, of muppetry you'll tolerate, so I haven't given them any plastic £10 notes, or indeed money in any other form since.

    1. DavCrav

      Re: Tesco, dates, social media

      "Of course "legal tender" is a strictly limited concept, and shops can choose not to accept currency pretty much arbitrarily; it's why your local corner shop is in its rights to put up "No £50 note's" signs."

      If they haven't given you the goods beforehand they can stipulate any method of payment at all, including chickens (as long as they have a GBP equivalent for VAT reasons). They can also decline right up until the payment has been accepted. They also don't need to provide change, which is how vending machines get away with it.

      If you already have the goods, then they cannot refuse to accept £1 coins, but again don't have to give change. They can in theory decline any other method, but you can often get a debt discharged if you can prove they have refused reasonable methods of payment.

    2. katrinab Silver badge

      Re: Tesco, dates, social media

      If the petrol station refused them, then legal tender rules do apply and you get the petrol for free.

      1. ibmalone

        Re: Tesco, dates, social media

        Think this one might be lawyer territory. While it seems to be the case that with petrol you are settling a debt (as the goods have already been supplied, though if not you could do a little dance of having payment refused and then filling out whatever inability to pay form they have to create a debt), there is mixed advice about when legal tender actually settles a debt. Bank of England and the Royal Mint slightly differ ("pays into court"), with this heroic freedom of information request eventually getting the response that they should seek legal advice. And at the end of the day you are dealing with someone who doesn't really know the law either and is just doing what their manager told them.

        1. ibmalone

          Re: Tesco, dates, social media

          Though in the course of checking I discovered this man who has been terrorising Tesco in Devon and Cornwall.

  19. Paul Herber Silver badge

    I'm Julian date and this is my friend Sandy date!

    1. Anonymous Coward
      Anonymous Coward

      bona to vada you trolling along here!

      1. CAPS LOCK

        You don't hear much Polari on El Reg much these days...

        ...and it's been too long since a game of Morning Crescent broke out...

        1. I ain't Spartacus Gold badge

          Re: You don't hear much Polari on El Reg much these days...

          CAPS LOCK,

          GASP! The horror! It's Mornington Crescent!

          Which means you're immediately in Nidd.

          Gospel Oak.

          1. ibmalone

            Re: You don't hear much Polari on El Reg much these days...

            Morning crescent is what I sometimes have for breakfast, occasionally with ham and cheese.

            Wait. Croissant. Morning croissant.

            Gare du Nord.

            1. I ain't Spartacus Gold badge

              Re: You don't hear much Polari on El Reg much these days...

              Gare du Nord.

              Ooh. Interesting. I didn't know we were playing the Angevin Variation.

              In which case I shall counter your Morton's gambit with:

              Cockfosters.

              1. ibmalone

                Re: You don't hear much Polari on El Reg much these days...

                I didn't know we were playing the Angevin Variation.

                Damn, if I'm honest I thought it was Roquefort Rules. Can I shunt? Who's south?

  20. Anonymous Coward
    Anonymous Coward

    Barking mad, are we?

    > "since much of the US insists on the barking mad month/day/year format,"

    What's so barking mad about it? If it made sense, half the programmers in the USA would be unemployed! Half of the code in my programs end up being convoluted day/date conversion routines. Viva la madness!!

    1. DavCrav

      Re: Barking mad, are we?

      "If it made sense, half the programmers in the USA would be unemployed!"

      The other half are writing accountancy software.

    2. DiViDeD

      Re: Barking mad, are we?

      convoluted day/date conversion routines

      Also true for the mere scripting languages. Try converting to proper dates when the US date formats have already had Excel or Access run their helpful eyes over them ("12/1/2018"? Oh that's easy - it's the 12th Jan. "5/22/2018"? no idea - let's leave it as text. "11/22"? OK, that'd be 0.5. No worries - happy to help)

      There are people working in the US who I've never met, but their names are writ high on my ToDo death list.

  21. Mr Dogshit

    Every little helps™

    1. Aladdin Sane

      The Tesco sign in Yeovil was vandalised so it read "very little helps"

      1. Vincent Ballard

        Why did the vandal not also remove the s?

  22. VeganVegan
    Flame

    Too many dates

    I feel inundated if not intimidated by all these date formats. Many of them predate / antedate the modern era, so why shouldn't we just invalidate a whole bunch of them, consolidate the remainder, select a very few as candidates that accommodate the most widespread current usage, elucidate which of this small subset gains widespread adoption, and mandate its usage?

    It would make life much more sedate.

    1. Nick Kew
      Coat

      Fishing for jokes

      I fear there's no meat on your cheesy jokes. If I egg you on, will you milk it for all it's worth?

      (mine's the fake leather-and-fur one)

      1. VeganVegan
        Happy

        Re: Fishing for jokes

        There is a question about meat,

        Whether there’s any to eat.

        Given eggs and cheese,

        Some milk, if you please,

        Bacon would be hard to beat!

        (Please substitute kippers, if that is your preference).

  23. Frumious Bandersnatch

    'struth

    I ain't gonna work on Maggie's farm no more :(

  24. IGotOut Silver badge

    I spotted it a mile off.

    Just because a major US motoring manufacturer insists on the bloody format.

    To make it even more confusing try matching up our system (week numbers) with this.

    So this year week one started on 18365 and week two 19006.

    It's even more confusing as the years move on and the dates get more skewed.

  25. TheSkunkyMonk

    Ordinal Date, Julian Calendar still had months thank god.

  26. crediblywitless

    In whose world is this "Julian date format"?

    1. I ain't Spartacus Gold badge

      He's Brian Date Format's brother...

  27. Big_Boomer Silver badge

    I used to work for a company that stored dates in its product database as the number of days since the 1st of January 1901. When I asked why, I was told "because" and given all the crappy jobs as an incentive to never ask again. Since I left I've been informed that they now use SQL Date format. The American M-D-Y date system is stupid, as is the Kazakh Y-D-M, the European D-M-Y date system is only marginally less stupid. Only the ISO date system of YYYY-MM-DD HH:MM.SS.mmm.uuu.nnn.ppp.fff.aaa makes any sense at all, although basing it on the the birth date of one particular person is also pretty stupid.

    However, it's all a human invention so it's bound to be a neurotic f***ed up mess of a system.

  28. sketharaman

    I'm not sure what's the international / ISO standard but, ever since I switched to 26 June 2019 format - whatever it's called - neither me nor my readers / customers from across the world have had any confusion.

  29. herman

    This line from ISO 8601 made my eye twitch just a wee little bit:

    "Note 2 to entry: In IEC 60050-113:2011, 113-01-03, time according to the space-time model is defined to be the one-dimensional subspace of space-time, locally orthogonal to space."

    Are these ISO guys from the Committee for Real Time perhaps?

    1. hitmouse

      Check with the local planning office in Alpha Centauri

  30. hitmouse

    I've noticed that Amazon is putting things into its Australian catalogue with MMDDYYYY dates but interpreting them as DDMMYYYY, so products that are actually available now are not available for another |MM-DD| months.

    Of course if you try to tell one of the Amazon support droids, then they just suggest something like you reinstall your browser. ( I reported spelling errors in the Kindle Android app user interface and I was told to reinstall the app....) . What was it that Jeff Bezos said about making three good decisions per day??? I hope they balance out the millions of bad decisions made as a result of his one decision to remove thought processes from his product support.

    1. Ken Shabby

      You should have told him politely to stick his suggestion "up his date"

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon

Other stories you might like