Forum Replies Created

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

  • RE: T-SQL Development Standards

    You might want to read through this post.

    I found it helpful.

    On the second page Jane posted an excellent standards document.

    http://www.sqlservercentral.com/Forums/Topic566838-146-2.aspx

  • RE: Procedure proble.

    PhilPacha (10/23/2008)


    It doesn't matter how quickly it can be done WRONG. 😉

    Why is it wrong to convert it to a table?

  • RE: Procedure proble.

    OK. That works. But it's still a lot slower. For four elements it was 16 ms. Joining to the table was 3 ms.

  • RE: Procedure proble.

    upperbognor (10/23/2008)


    I've also seen this approach taken when looking for GUID's in a input list of GUIDs. This method looks up every value in the table in your list...

  • RE: Procedure proble.

    You can use a function to split the CSV parameter into a table, and then join to that table.

    There are many different functions out there that will perform the split....

  • RE: Clarification of NoLock

    krayknot (10/20/2008)


    It is not advisable to use NOLOCK as it returns the uncommited rows that may affects the final output

    That is quite a generalization. If you are reporting off of...

  • RE: Help needed in removing dynamic SQL

    Garadin (10/17/2008)


    To be quite honest, I'm not even sure I'd need dynamic SQL for this project. I can probably circumvent it entirely with a little bit more work.

    It really...

  • RE: Help needed in removing dynamic SQL

    Garadin (10/16/2008)


    There definitely wouldn't be any manual typing in. It would all be check boxes or drop downs. However, because it's on the internet, I'm not necessarily happy...

  • RE: Help needed in removing dynamic SQL

    Garadin (10/13/2008)


    rbarryyoung (10/13/2008)


    Hmm, maybe I should write an article...:hehe:

    I was kinda hoping you'd come to that conclusion :P.

    We'll likely be generating a dynamic column list for the final select, as...

  • RE: Query Execution Plans & Recompilation

    Thanks! That clarified a lot.

  • RE: Query Execution Plans & Recompilation

    I'm still a little confused about how the query plan works.

    Here's what I thought:

    There is one query plan per stored procedure. When the query is run an execution context is...

  • RE: Query Execution Plans & Recompilation

    GilaMonster (10/16/2008)


    Sure. This is the classic example

    CREATE PROCEDURE AllOrSearch (

    @SomeCode VARCHAR(30) = NULL

    )

    AS

    IF @ID is null

    SELECT * FROM SomeTable

    ELSE

    SELECT * FROM SomeTable WHERE SomeColumn = @SomeCode

    If...

  • RE: Query Execution Plans & Recompilation

    GilaMonster (10/16/2008)

    This can, in some cases, lead to poor query plans for some branches of the if/else that will hinder performance for some executions.

    Can you please elaborate on this? When...

  • RE: Convert rows into columns

    You mentioned earlier that you had tried to create a cross tab report, but were unsuccessful.

    Can you post that code here?

    Also, are you allowed to use dynamic SQL from inside...

  • RE: Convert rows into columns

    Shree (10/13/2008)


    Hi, when I run the code , its giving me Incorrect syntax near XML.

    That's strange. I copied & pasted the code straight from the forum. It's not giving me...

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