Forum Replies Created

Viewing 15 posts - 5,461 through 5,475 (of 7,484 total)

  • RE: Cursor Causing Performance Issues

    CELKO (9/11/2011)


    While temp tables in the Sybase/SQL Server model can be indexed, constrained, etc. nobody does. They really are like a deck of punch cards. Compare this to the ANSI/ISO...

  • RE: Database Collation

    Good easy question.

    I got it wrong because I am not case-sensitive when scanning SQL :blush::laugh:

  • RE: add a column and if else the select statement?

    mattech06 (9/11/2011)


    cheers tom. I've tried the sql and the email field isn't getting populated though. Both of these have 2 related records each in the Phone table for type 5...

  • RE: add a column and if else the select statement?

    I think I get it: is this what you mean?

    The phone table contains two lines for each patient - one marked (in the dbphonetypeid column) 9 which contains the email...

  • RE: Cursor Causing Performance Issues

    CELKO (9/10/2011)


    Another good rule of thumb is that no procedure should be longer than one page.

    It's a good rule of thumb for any language, not just SQL; but of...

  • RE: Cursor Causing Performance Issues

    GilaMonster (9/10/2011)


    That might get you a percent or two improvement at most.

    If "that" means the OPs suggestion of using uodate...where current it won't give even a couple of per...

  • RE: Priority based selection from SQL JOIN

    You give no indication how to determine which row in T2 corresponds to a row in T3, or which row in T1 corresponds to a row in T2. Do...

  • RE: Index hint: hash, merge in sql server 2000,2005

    GilaMonster (9/10/2011)


    Fix non-SARGable predicates, add indexes, fix catch-all queries (very common), suggest application rewrites (to stop being chatty), simplify SQL code, remove cursors.

    Another one that is sometimes very useful is...

  • RE: add a column and if else the select statement?

    If you realy mean just add another column in the output of the select statement, then you can go with Lutz' fiorst option - use a case function. this...

  • RE: A Matter of Degree

    Came across this a couple of years late. Didn't see it when it first came out (befoe Ijoined SQLS Central). Saw it now because it's linked from Steve's editorial...

  • RE: The Apprentice

    Grant Fritchey (9/9/2011)


    I came into this career without a CS degree. Still don't have one. What I do have is 20 years of experience (and that mostly is 20 years...

  • RE: The Apprentice

    Hey Steve, are you saying that my gebneration had no serious developers?

    From my point of view, it would be moe accurate to say that most senior developers didn't got to...

  • RE: How do we get the most resent row

    You need to use a derived table to select the maximum sequence number and whatever else you need from the history, and join that derived table with the case table...

  • RE: Using MAX with UNION

    Looking at the code, one thing I can think of is that maybe you are trying to use MAX in one of the components of the union, instead of in...

  • RE: Another bug in SS?

    GilaMonster (9/9/2011)


    Want to be really evil? (now we are getting into the mess that is nested transactions, named transactions and error handling)

    How many rows does that select return? 0, 1,...

Viewing 15 posts - 5,461 through 5,475 (of 7,484 total)