Forum Replies Created

Viewing 15 posts - 226 through 240 (of 658 total)

  • RE: CTE

    Carlo Romagnano (9/26/2013)


    On my server sql2008 r2 my script runs in 2 seconds vs 6 secs of Lynn's.

    The difference is because you've added an extra join so are returning more...

  • RE: Executing Dynamic SQL

    ksatpute123 (9/25/2013)


    Comments posted to this topic are about the item <A HREF="/questions/Dynamic+SQL/102252/">Executing Dynamic SQL</A>

    Nice idea, but not sure about the execution. I knew it was going to fail due to...

  • RE: CTE

    Carlo Romagnano (9/25/2013)


    ... and you do not need semicolon.

    But at some point in the future you will need a semi-colon for everything. Best practice IMO is to use them for...

  • RE: CTE

    Carlo Romagnano (9/25/2013)


    With complicated CTE, the optimizer does not choose the best plan.

    I have sometimes found that as well.

    I have also occasionally found the opposite, where using a CTE has...

  • RE: Dynamic Query

    I got this wrong because I assumed the "*/" was only on a new line because it had been wrapped by the narrow display 🙁

  • RE: Variable Declaration

    Leifton (9/19/2013)


    Not sure how everyone is getting this right. The script fails (as i suspected) in SQL 2005, 2K8 and 2K12. Since the first block is not run...

  • RE: Variable Declaration

    I'd never have got this right if it weren't for the discussion following the other recent variable declaration question!

    Interesting to know how SQLServer behaves - but hopefully such shoddy code...

  • RE: Reserved Words - 1

    L' Eomot Inversé (9/18/2013)


    I think that wa the point of the question: the seting of quoted_identifier only affects the treatment quote marks as delimiters. not the treatment of square brackets.

    You're...

  • RE: Reserved Words - 1

    Nice question, but I can't understand why the stuff about quoted identifiers is in the explanation. Surely the result is identical even if QUOTED_IDENTIFIER is On?

  • RE: wildcards

    L' Eomot Inversé (9/11/2013)


    Do you mean 80 messages or 400 messages or something in between? A count of pages is meaningless, since people set their forum view to have...

  • RE: wildcards

    Dear Steve

    Can you change the points system so that if someone replies pointing out an error and 8 pages of people have already replied pointing out the same error in...

  • RE: wildcards

    Todd Reddinger (9/11/2013)


    The correct answer is 0 since 'steppenwolf' is 11 characters long and would return an error.

    It's amazing that in 7 pages of discussion, you're the first person to...

  • RE: wildcards

    Raghavendra Mudugal (9/11/2013)


    I just analyzed the question without executing and picked the right answer.

    You clearly didn't analyse it very well then 😉

  • RE: Behavior of trigger

    Stewart "Arturius" Campbell (9/10/2013)


    another notch to my list of reasons to dislike triggers

    Really? Can't say this behaviour would appear anywhere on my list of bad things about triggers. I've...

  • RE: wildcards

    Koen Verbeeck (9/11/2013)


    Indeed. As if I'm going to count the number of characters in Steppenwolf.

    Why wouldn't you? I did, and got it wrong as a result.

    I was guessing though, as...

Viewing 15 posts - 226 through 240 (of 658 total)