The Worst Comments

  • 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.

  • 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.

    Change is inevitable... Change for the better is not.


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

  • 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.

  • 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.

  • 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.

    Change is inevitable... Change for the better is not.


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

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

  • 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 156 (of 156 total)

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