The Worst Comments

  • miapjp

    Right there with Babe

    Points: 765

    When I worked in a larger company and had to do maintenance programming, I learned to write better errors because I hated this kind of thing.  SQL Server gives you all the information you need to put out a helpful error.

  • Jeff Moden

    SSC Guru

    Points: 995161

    Now THAT's funny.  Talk about "Team Work", eh?

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column.
    "If you think its expensive to hire a professional to do the job, wait until you hire an amateur."--Red Adair
    "Change is inevitable... change for the better is not."
    When you put the right degree of spin on it, the number 3|8 is also a glyph that describes the nature of a DBAs job. 😉

    Helpful Links:
    How to post code problems
    Create a Tally Function (fnTally)

  • Steve Jones - SSC Editor

    SSC Guru

    Points: 716659

    MVDBA (Mike Vessey) wrote:

    I came across a stored procedure recently where there were 2 developers clearly arguing we didn't have source control for sql at the time of the argument (way before I started) and all dev work was on the live server, so all code changes were commented out as a rollback strategy (sigh) the comments went something like this...

     

    I dislike some sort of multiple comment discussion inline. I think this is better in a header (or as a commit in a VCS). I prefer that a comment inline is just about the current state of code and why something is implemented in a certain way.

  • Steve Jones - SSC Editor

    SSC Guru

    Points: 716659

    mike.sortino wrote:

    I think it is a ridiculous waste of time when someone comments on the obvious, like: counter++;   // increment counter Really??

    I blame professors are unis for this. That's the type of nonsense they asked me to write, or they gave extra credit for including.

  • Jeff Moden

    SSC Guru

    Points: 995161

    Steve Jones - SSC Editor wrote:

    mike.sortino wrote:

    I think it is a ridiculous waste of time when someone comments on the obvious, like: counter++;   // increment counter Really??

    I blame professors are unis for this. That's the type of nonsense they asked me to write, or they gave extra credit for including.

    Heh... totally inappropriate comment... I'd have commented "Bump the Counter". 😀

    Such seemingly ridiculous comments make it easy to find the obvious because you don't have to shift your mind from looking at comments to looking at code, especially when you're under the gun.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column.
    "If you think its expensive to hire a professional to do the job, wait until you hire an amateur."--Red Adair
    "Change is inevitable... change for the better is not."
    When you put the right degree of spin on it, the number 3|8 is also a glyph that describes the nature of a DBAs job. 😉

    Helpful Links:
    How to post code problems
    Create a Tally Function (fnTally)

  • David Conn

    SSCertifiable

    Points: 5581

    Still using RPG. It's Alive and well. We're currently running RPG IV on an IBM Power System with IBM i 7.3

  • Sean Lange

    SSC Guru

    Points: 286486

    David Conn wrote:

    Still using RPG. It's Alive and well. We're currently running RPG IV on an IBM Power System with IBM i 7.3

    We finally decommissioned our last RPG programs within the last 2-3 years.

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/

Viewing 7 posts - 151 through 157 (of 157 total)

You must be logged in to reply to this topic. Login to reply