• monkeyPushButton (unregistered)

    The real WTF is the lack of closing tag for the

    , right?

    <td colspan="5">
      <h2>There are no unread messages/notices in your inbox
    </td>
    

  • AndyL (unregistered)

    In before the 30th comment!

  • Drew (unregistered)

    There are no unread comments in your inbox

  • Yazeran (unregistered)

    Wow!

    Although I have personally made some bizarre database tables that one takes the record (dum dum tsh).

    I could understand the first approximation about only 30 active notices, but designing a database with a hard limit on the total notices, that's just plain stupid.

    The add the gem about no messages to display......

    Some people should just simply not be let near a computer let alone a compiler/database...

    Yours Yazeran

  • Piercy (unregistered)

    There are no unread messages in your comments

  • MainCoder (unregistered)

    Not really a WTF. Table limited to 30 notices? Yeah, but who cares. I will work and it'll just become one of those quirks that every system has. Always saying no messages? The feature was simply not yet implemented. Just something to do with a few hours to spare.

  • (cs)
    <obvious two weeks notice joke />
  • Anonymous (unregistered)

    So half the implementation was crap and the other half was non-existent. Don't know about anywhere else but that sounds like a regular day at the office round here.

  • Paul Berry (unregistered)

    You can normalise someone with a steamroller, right?

    ::)

  • alomondo (unregistered)

    Is this a true story?

  • Dazed (unregistered)

    Did Nigel have a sister called Paula?

  • My Freaking Goodness! (unregistered)

    This is just about the easiest DB project in the world. It's almost the canonical example of a many to many relation.

    Table Users (UserID, other-info) Table Notice (NoticeID, NoticeText, Expires) Table UserNotice (UserID, NoticeID, Acknowledged)

    I'll leave data types and references as an exercise for the reader.

  • ThomasP (unregistered) in reply to AndyL
    AndyL:
    In before the 30th comment!

    You should have waited, your post will be reused when everyone gets on here for their lunch break.

  • groogs (unregistered)

    Why is building a system like this that is limited to 30 notices, and requires re-use considered OK?

    This is the kind of decision that leads to a WTF being posted 6 to 12 months from now, after someone has modified this system (eg, to have a log what notices users saw and accepted) using the same type of dumb design, and then a real developer comes in to see why it isn't working.

    This is just short sighted, and someone designing this should be ridiculed on here. So should the developer that approves the design.

  • Jim (unregistered)

    If this guy had any skill he would have just implemented the whole thing in two Javascript arrays. What a retard.

  • (cs) in reply to My Freaking Goodness!
    My Freaking Goodness!:
    This is just about the easiest DB project in the world. It's almost the canonical example of a many to many relation.

    Table Users (UserID, other-info) Table Notice (NoticeID, NoticeText, Expires) Table UserNotice (UserID, NoticeID, Acknowledged)

    I'll leave data types and references as an exercise for the reader.

    All tinyints, obviously. At least I got that much out of the article.

  • (cs)

    Sorry, but you guys are all wrong - Nigel was, actually, a genius.

    He knew all along that nobody actually reads these kinds of notices, and that having them show up all the time would just irritate the users. Therefore he put some crap in to allow people to think they were adding them - keeping management happy - and didn't show them to the customers at all - keeping the customers happy.

  • citricsquid (unregistered) in reply to valerion
    valerion:
    Sorry, but you guys are all wrong - Nigel was, actually, a genius.

    He knew all along that nobody actually reads these kinds of notices, and that having them show up all the time would just irritate the users. Therefore he put some crap in to allow people to think they were adding them - keeping management happy - and didn't show them to the customers at all - keeping the customers happy.

    This. I'd employ Nigel.

  • Jauco (unregistered)

    So... Basically Nigel was asked to implement e-mail right?

  • AdT (unregistered)

    No one will ever need more than 30 notices.

    Or zero for that matter.

    PS: I'm waiting for the comments explaining how this was a perfectly acceptable use of database denormalization / disintegration.

  • Anon (unregistered) in reply to groogs
    groogs:
    Why is building a system like this that is limited to 30 notices, and requires re-use considered OK?

    Because management doesn't understand what is possible and the developer tells them that this is the only way it can be done.

  • Ratchetr (unregistered) in reply to My Freaking Goodness!
    My Freaking Goodness!:
    This is just about the easiest DB project in the world. It's almost the canonical example of a many to many relation.
    Nigel prefers the many to many but not too many design pattern. Takes fewer resources.
  • (cs) in reply to Jim
    Jim:
    If this guy had any skill he would have just implemented the whole thing in two Javascript arrays. What a retard.
    Missing smiley I assume?
  • Crabs (unregistered) in reply to Jauco
    Jauco:
    So... Basically Nigel was asked to implement e-mail right?

    Sort of. There is use in it. The company can't guarantee the user checks their e-mail before using their site. They can guarantee, however, that the notices show up before the user can do anything else on their site. This could be a useful feature.

    And actually, if he did it right, this could be used to display 2^30 messages, rather than just 30. That should be enough messages for anybody.

  • clickey McClicker (unregistered) in reply to valerion
    valerion:
    Sorry, but you guys are all wrong - Nigel was, actually, a genius.
    Could be he left the company because he found top management using offshore banks for something odd and decided to bail first (very possible these days). Any word on his stock options?

    He got out so fast leaving all the code in an unpolished state. Had he used comments it would have been plain to see how this part fit into the grand final project which would have been a work to behold.

    Genius, obviously!

  • clickey McClicker (unregistered) in reply to Crabs
    Crabs:
    And actually, if he did it right, this could be used to display 2^30 messages, rather than just 30. That should be enough messages for anybody.

    But will it fit in the 640k of ram?

  • Quantum Mechanic (unregistered)

    It's hard to say if Nigel was in over his head or a @#$% con-artist who knew exactly what he was doing. Cripes!

  • Fixmyship (unregistered)

    Obviously he was going to use the IDXX to store 1 message per user and find it by constructing an id in base 30 - up to (30^30) 2.05 * 10^44 notices in the system total.

    A reasonable solution would be 6 notices per customer - a total of (30^5) 24 300 000 notices possible in the system.

  • (cs)

    I'm not sure why everyone is so upset about the database design.

    Hypothetically, if the page could display at most fifteen notices, the database design could scale to twice the current usage. While not great scalability, it's still something.

    If the page displayed at most two notices, the database would have 15 times scalability. That's pretty impressive.

    But this design is better. The limit (from the positive side) as the number of alerts displayed by the page approaches 0 is unbounded; that is to say that this design has infinite scalability, without additional hardware. That's damned impressive.

    We should all aspire the to standards set by Nigel.

  • (cs)

    I can't believe nobody has yet quoted:

    "We're only making plans for Nigel We only want what's best for him We're only making plans for Nigel Nigel just needs this helping hand And if young Nigel says he's happy He must be happy He must be happy in his work We're only making plans for Nigel He has his future in British Steel We're only making plans for Nigel Nigel's whole future is as good as sealed And if young Nigel says he's happy He must be happy He must be happy in his work Nigel is not outspoken But he likes to speak And loves to be spoken to Nigel is happy in his work We're only making plans for Nigel"

    On the other hand, British Steel isn't looking too clever these days, either.

    I look forward to receiving Nigel's CV someday:

    "Implemented clone of entire email system using only Tinyints..."

  • Anonymous (unregistered) in reply to MainCoder
    MainCoder:
    Not really a WTF. Table limited to 30 notices? Yeah, but who cares. I will work and it'll just become one of those quirks that every system has. Always saying no messages? The feature was simply not yet implemented. Just something to do with a few hours to spare.

    You... you're being sarcastic, right? This whole project is like a 2 hour job at most, and that's without any stupid limitations like a 30 notice maximum.

  • CynicalTyler (unregistered)
    he opened up the code file expecting some incredibly clever code
    Idiot.
  • mh (unregistered)

    From such small seeds do Enterprise systems grow. Scoff ye not! SAP may have started out like this (...actually...)

  • CaRL (unregistered)
    system was to allow management to communicate with customers about new products
    So, basically, the manager said "Make me a SPAMbot, but force the customers to read my drivel."

    When developers / managers get that arrogant, it makes me wonder if it is time to legalize more forms of torture. But, lacking that, if we can put the most clueless developers to work writing this stuff it should at least slow these jerks down somewhat.

  • bob (unregistered)

    The real take away here is that not all coders can design a database. I've even seen competent coders produce similar schemas -- it's a separate skill.

    God have mercy on the incompetent.

  • WC (unregistered) in reply to Crabs
    Crabs:
    And actually, if he did it right, this could be used to display 2^30 messages, rather than just 30. That should be enough messages for anybody.

    But only 1 at a time.

  • (cs) in reply to CaRL
    CaRL:
    So, basically, the manager said "Make me a SPAMbot, but force the customers to read my drivel."

    When developers / managers get that arrogant, it makes me wonder if it is time to legalize more forms of torture. But, lacking that, if we can put the most clueless developers to work writing this stuff it should at least slow these jerks down somewhat.

    Interesting theory. Wrong, but interesting. It's entirely legal for businesses to send direct mail to customers with pre-existing business relationships (which is obviously the case here), and this isn't even direct mail. Nobody is being forced to log in and read the notices. If a customer decides to sever the relationship, he will never see a notice, ever.

    I'll bet that you're one of those people who are against all forms of advertising, aren't you?

  • Lego (unregistered) in reply to Quango
    Quango:
    Jim:
    If this guy had any skill he would have just implemented the whole thing in two Javascript arrays. What a retard.
    Missing smiley I assume?
    Nah, this looks like TopCod3r in disguise!
  • (Visitor) (unregistered)

    Unbelivable.

  • (cs)

    The whole acknowledgment thing seems like an awkward set of specs. You're showing the user a notice, but, you allow them to get rid of the notice by acknowledging it, but, you don't make it such that the user must acknowledge it once they've seen it and, you don't keep a record of what has been acknowledged.

    Also, there's no description of how a notice gets entered. It could very well be that there is a stock set of thirty generic notices that were set up to choose from.

    It seems that the no new messages page is most likely a default page, and a placeholder.

    I think it's clear that the guy just hadn't finished, and was working with inadequate information to get his job done.

  • sxeraverx (unregistered) in reply to bob

    Last summer I worked at a place like this. The DBA was actually coder who was in reality a biologist. "Sure, normalization's nice and all, but this works. Besides, there's no time for a complete rewrite." Loads of tables named "temp_x_1", "temp_X_1", "temp_X1", etc., most of which held exactly two rows and about 50 columns.

  • PuffyJacket69 (unregistered) in reply to undrline
    undrline:
    The whole acknowledgment thing seems like an awkward set of specs. You're showing the user a notice, but, you allow them to get rid of the notice by acknowledging it, but, you don't make it such that the user *must* acknowledge it once they've seen it and, you don't keep a record of what has been acknowledged.

    Also, there's no description of how a notice gets entered. It could very well be that there is a stock set of thirty generic notices that were set up to choose from.

    It seems that the no new messages page is most likely a default page, and a placeholder.

    I think it's clear that the guy just hadn't finished, and was working with inadequate information to get his job done.

    This was what I was thinking after I read the article...

    kind of a lame wtf...

  • Jimbo (unregistered)

    The lack of comments here (even of the normal Grammar-Nazi style) speaks volumes for what people thought of this one.

    Sounds to me like there were 30 TYPES of messages...

  • BadBaby13 (unregistered) in reply to Crabs
    Crabs:
    Jauco:
    So... Basically Nigel was asked to implement e-mail right?

    And actually, if he did it right, this could be used to display 2^30 messages, rather than just 30. That should be enough messages for anybody.

    Actually, if you wanna get technical about it... you could build a whole database system, serialize it and store it in the notice text of one of the notices. If the text had a memory constraint.. you could serialize the database system you wrote across several message texts ordered by ID.

    Not only would this solution allow you to create as vibrant and perfect of a normalized design entirely seperate from the restrictions that you might have gotten stuck with from the initial database design, but it would also allow you to make as many users and messages as memory would allow!

    I have used this technique many times, and actually have a standard library that allows me to do it in no time. Pray that none of you EVER run across a system I have maintained!

    also - we have to give nigel the benefit of the doubt. depending on the orm software nigels managers might have liked - the database might be perfect just the way it is!

    Mwahahahahaha!

  • misc (unregistered) in reply to MainCoder

    Not really a WTF!? Are you effin kidding me.

  • (cs) in reply to sxeraverx
    sxeraverx:
    Last summer I worked at a place like this. The DBA was actually coder who was in reality a biologist. "Sure, normalization's nice and all, but this works. Besides, there's no time for a complete rewrite." Loads of tables named "temp_x_1", "temp_X_1", "temp_X1", etc., most of which held exactly two rows and about 50 columns.
    Ah yes, "Third Cretinised Form." It's quite normal around here.

    0th Cretinised Form: A flat file, named "temp". Optionally, this may be stored on "/tmp" or "C:\Temp".

    1st Cretinised Form: One file is not enough for squillions of Bits-O-Data. Make more files: "temp_x", "temp_xx", or (for the truly naughty) "temp_xxx".

    2nd Cretinised Form: Separation of implied function. Who can tell what relationship "temp_xxxxxxxx_swalk" has to "temp_x_f*off"? Add a primary key for ordinality (yes yes, I know this should have been done first. We're talking cretins, here): "temp_x_1", "temp_x_2", etc.

    3rd Cretinised Form: Oh look, there's a caps key on my keyboard. Great! There's a semantic difference here, but I'm not going to tell you what it is.

    Just a small Codd joke.

    Anyway, who the heck needs tables? Unless they're wooden.

  • Curious (unregistered)

    Is the original poster on here? I'd love to know how long it took Nigel to come up with this. The "There are no notices" messages is sort of understandable if this was all the work he had completed after one day. It's a little less forgivable if this was the totality of his work after six months.

  • Andyman (unregistered) in reply to Crabs

    Nice, had not thought about that...

  • Government Steering Committee (unregistered) in reply to Quango
    Quango:
    Jim:
    If this guy had any skill he would have just implemented the whole thing in two Javascript arrays. What a retard.
    Missing smiley I assume?

    I assumed that the Internet was not limited to Americans and that not spelling out the sarcasm for every Tom, Dick and Retard was his way of fighting the ever-increasing stupidity prevalent on the Internet today.

    ;) <-happy?

  • Downfall (unregistered)

    Nigel, please.

Leave a comment on “Noticing Something Strange”

Log In or post as a guest

Replying to comment #:

« Return to Article