• Steven (unregistered)

    Duh. Everybody knows OCTOBER and NOVEMBER should be capitalized... (zeroth?)

  • blip (unregistered)

    <bill> Would you mind telling me in which month you were born? <al> NO <bill> We don't appear to have that value in our database - I'll add it.

  • tjb (unregistered)

    select * from month where month = 'frist'

  • potNPan (unregistered)

    +-------------+ | month | +-------------+ | NULL | | FRIST? | | SCEOND | | 4 | | T | | C | | A | | 8 | | 15 | | L | | 16 | | P | | D | | S | | 23 | | 42 | | YES | | | | 0 | +-------------+

  • (cs)

    Judging by the fact that both NULL and the empty string occur, I infer it's not Oracle. At least something is sane.

  • No Name (unregistered)

    Sure, "DELETE FROM month" should fix the problem

  • bob (unregistered)

    holy hell

  • RuBen (unregistered)

    Well i can finally say I'm born T-32-198L

  • (cs)

    It's missing FILE_NOT_FOUND.

  • David (unregistered)

    Data validation, DO YOU SPEAK IT?!

  • Peyote `Simon` Joints (unregistered)

    Actually, I was born on the 11st of NULL, 2147483647 BC. This table looks fine.

  • Giq (unregistered)

    "File Not found" is well known, valid month name, but is missing there.

  • ¯\(°_o)/¯ I DUNNO LOL (unregistered)

    Not only is it missing FILE_NOT_FOUND, as previously mentioned, it is also missing the months of true, false, True, False, TRUE, and FALSE.

    And also FAIL FAIL, FAIL FAIL, FAIL FAIL.

  • XXXXX (unregistered) in reply to Peyote `Simon` Joints
    Peyote `Simon` Joints:
    Actually, I was born on the 11st of NULL, 2147483647 BC. This table looks fine.
    It's just this kind of carelessness that shows why we should have a table of milliseconds->readable date strings. ------------------------------------------------------------- 00000000000000000000000000000000 | 1970-JAN-01 00:00:00.00000 00000000000000000000000000000001 | 1970-JAN-01 00:00:00.00001 00000000000000000000000000000002 | 1970-JAN-01 00:00:00.00002 etc. etc. etc. ------------------------------------------------------------
  • (cs) in reply to RuBen
    RuBen:
    Well i can finally say I'm born T-32-198L
    My goodness, what a coincidence. I just tried using a T-32-198L in a project, last week. It exploded, however.
  • (cs) in reply to TGV
    TGV:
    Judging by the fact that both NULL and the empty string occur, I infer it's not Oracle. At least something is sane.

    Judging by the mysql> prompt I'd say it's not Oracle also.

  • GWO (unregistered)

    The real WTF is saying "none are", and not "none is". None takes singular verb forms.

    Captcha: luptatum - The greatest werewolf jazz pianist of all time.

  • Nagesh (unregistered)

    Probably is ain't being worse then meking code for luner calendar. When Pakistani entering burth month, often time is using Rahab or Shaban rather then May or June. Intarnationalization ain't being something to forgot.

  • dark Yuris (unregistered)

    if month is purely informational and business logic does not depend on it - this is acceptable

  • (cs) in reply to GWO
    GWO:
    The real WTF is saying "none are", and not "none is". None takes singular verb forms.

    Captcha: luptatum - The greatest werewolf jazz pianist of all time.

    According to this source it's a little more complicated than that.

    Summary: None can be singular or plural, unless it quantifies a singular or mass noun. Don’t believe anyone who says none has to be singular because it’s a contraction of not one. Both none of the meals is and none of the meals are are okay, and both none is and none are are okay. *None of the stuff are is ungrammatical, though.

  • TroelsL (unregistered)

    Why on Earth would you even have a MONTH table anyway? In case "they" decide to change them?

  • (cs)

    Oh my God, it's full of WTFs…

    It's "only" "missing": brillant, FILE_NOT_FOUND, septembruary, kajillion, and NOTIONAL_MONTH_AFTER_DECEMBER_FOR_INVENTORY_RECONCILIATION.

  • justsomedudette (unregistered) in reply to dark Yuris
    dark Yuris:
    if month is purely informational and business logic does not depend on it - this is acceptable
    To whom? Just because it doesn't break something doesn't make it right.
  • Kolja (unregistered)

    maybe the inventor of this table even came from the future and saw that they already invented the months NULL, T, C and so on and it was decided to write NOVEMBER always entirely uppercase, then the software is just future save.

  • Gyxi (unregistered) in reply to TroelsL

    That could make sense in some cases I guess if you want to use it for joining and do not want a 'magic number' in your database. Is Month=1 January or February. A 'Month'-table could tell you.

  • Fishcake (unregistered)

    So.....is TRWTF that it took 0.04 sec to run the query?

  • Silent D (unregistered)

    It's also missing rows for YES and YESVEMBER.

  • anon (unregistered) in reply to Fishcake
    Fishcake:
    So.....is TRWTF that it took 0.04 sec to run the query?

    Well, to be fair, someone else was running "select * from YEAR" at the same time. You really don't want to know what that table looks like, but suffice to say it slows the DB down just a little bit.

  • random generic guy (unregistered) in reply to ZPedro

    You forgot Smarch

    captcha: tego I'm thirsty, shall we to tego?

  • (cs)

    It's also missing Smarch.

    Edit: Damn, beat me by under a minute.

  • kbiel (unregistered)

    TRWTF is that even with an extra 16 months, they probably still missed most production deadlines.

  • Jan Doggen (unregistered)

    Let me guess:

    • The backdoor password is 3TCA12L4PDS7
    • The answer to the secret question is NO
  • (cs) in reply to TGV
    TGV:
    Judging by the fact that both NULL and the empty string occur, I infer it's not Oracle. At least something is sane.

    Is it NULL or is it the string 'NULL'?

    Also, is that the empty string or are there some blank spaces for padding?

  • An Old Hacker (unregistered) in reply to Zemm
    Zemm:
    TGV:
    Judging by the fact that both NULL and the empty string occur, I infer it's not Oracle. At least something is sane.

    Judging by the mysql> prompt I'd say it's not Oracle also.

    Win.

  • ufmace (unregistered)

    NULL has always been my favorite month of the year! The NULL rising over the horizon early in the morning, the scent of the NULL in the air, why it just can't be beat!

  • An Old Hacker (unregistered) in reply to anon
    anon:
    Fishcake:
    So.....is TRWTF that it took 0.04 sec to run the query?

    Well, to be fair, someone else was running "select * from YEAR" at the same time. You really don't want to know what that table looks like, but suffice to say it slows the DB down just a little bit.

    And... the runner-up.

  • techpaul (unregistered)

    Sorry missing Floopuary...

    See Dilbert for January 8th 2003 !!!

    This has been a known month for so long you think they would have remembered that one

  • (cs) in reply to Fishcake
    Fishcake:
    So.....is TRWTF that it took 0.04 sec to run the query?

    The table was not cached in memory, so it took 0.01 sec to execute.

    MySQL then took 0.03 seconds to try to determine WTF happened to corrupt the month table so horribly.

  • Brian (unregistered)

    Feature Request 985823: Please add month: Febtobuary

  • iwoas (unregistered) in reply to Zemm

    It may be a batch file called select.bat preceded by prompt mysql$g.

  • SB (unregistered)

    Having a look up table for commonly used data is a good idea, but yeah there is some legacy data in there that needs a cleanse.

    You could export this to xml and then load it in the cache of the application.

  • Toolbag (unregistered) in reply to TroelsL
    TroelsL:
    Why on Earth would you even have a MONTH table anyway? In case "they" decide to change them?
    In fact, they can change.

    You may not remember these old times, when the French tore down monarchy and decided to stand for a "Republic" thing. Well, they also decided to change days and months for almost 14 years.

    Weeks were ten days long, months were 3 weeks long, and added 6 days to make it even with Earth rotation.

    You may check "Republican Calendar" on wikipedia and laugh about how we French are lame, I grant you this right.

    However, never assume months are granted :)

  • (cs) in reply to XXXXX
    XXXXX:
    Peyote `Simon` Joints:
    Actually, I was born on the 11st of NULL, 2147483647 BC. This table looks fine.
    It's just this kind of carelessness that shows why we should have a table of milliseconds->readable date strings. ------------------------------------------------------------- 00000000000000000000000000000000 | 1970-JAN-01 00:00:00.00000 00000000000000000000000000000001 | 1970-JAN-01 00:00:00.00001 00000000000000000000000000000002 | 1970-JAN-01 00:00:00.00002 etc. etc. etc. ------------------------------------------------------------

    Not fine grained enough...it needs to be nanoseconds, these days. Be sure to provide for expansion to picoseconds (at least).

  • Matteo (unregistered)

    TRWTF is that it's missing OCTEMBER clearly.

    Captcha: luptatum: latin derivation of wolf. maybe.

  • Beorn (unregistered)

    It misses Apples.

  • Jeremy (unregistered) in reply to XXXXX
    XXXXX:
    Peyote `Simon` Joints:
    Actually, I was born on the 11st of NULL, 2147483647 BC. This table looks fine.
    It's just this kind of carelessness that shows why we should have a table of milliseconds->readable date strings. ------------------------------------------------------------- 00000000000000000000000000000000 | 1970-JAN-01 00:00:00.00000 00000000000000000000000000000001 | 1970-JAN-01 00:00:00.00001 00000000000000000000000000000002 | 1970-JAN-01 00:00:00.00002 etc. etc. etc. ------------------------------------------------------------
    Not a good idea. For one thing, who is going to pay people to type in all that data? For another thing, any project that large is bound to have some errors. I suggest whittling this down to just whole seconds, which would reduce the effort considerably. If you really need milliseconds somewhere, you can always interpolate.

    And, while I haven't bothered to write the code, my highly experienced programmer instincts suggest there might be an opportunity for recursion in there somewhere.

  • (cs)

    Up with anarchy! Define your own month! I happen to like month "Puce", personally.

  • iToad (unregistered)

    Is the spiffy ASCII art formatting a feature of MySQL or -God help us-, was it embeddeded within each record in the table, so it would print out like this when queried?

    Disclamer: I don't know anything about MySQL.

  • (cs)

    They would have been better off using RegEx.

  • (cs) in reply to iToad
    28 rows in set (0.04 sec)
    wow....

Leave a comment on “Representative Table”

Log In or post as a guest

Replying to comment #381704:

« Return to Article