Forum Replies Created

Viewing 9 posts - 301 through 309 (of 309 total)

  • RE: TSQL using parameters does not use the index

    Paul White (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    And it does not matter if you use uniqueidentifier or varchar(50)

    It is NVARCHAR(50).

    Do you really think there is no difference between indexing a GUID at 16...

  • RE: TSQL using parameters does not use the index

    Tom Van Harpen (3/18/2010)


    When this table is loaded there are about 800,000 rows that all have the same batchExecID, the next run loads about the same but with a new...

  • RE: TSQL using parameters does not use the index

    Paul White (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    Test again with 50000 unique GUIDs and a single GUID with 50000 copies.

    Now you are just being silly.

    Absolutely not.

    I believe that this is the exact scenario...

  • RE: TSQL using parameters does not use the index

    GilaMonster (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    I find it is more helpful to suggest solutions rather than saying what not to do.

    I'll be very happy to give a solution once the actual execution...

  • RE: TSQL using parameters does not use the index

    Paul White (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    The reason your example worked was not that you used UNIQUEIDENTIFIER instead of string, it was that you had a unique index and you had no...

  • RE: TSQL using parameters does not use the index

    GilaMonster (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    Anyway, I do not think you will ever have range scans with GUID:s. Looking up a specific value will work perfectly even if the index is heavily...

  • RE: TSQL using parameters does not use the index

    GilaMonster (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    Sure, why not ? The only possible ill effect is that it might slow down insertions to the table slightly. This will only be a problem if...

  • RE: TSQL using parameters does not use the index

    Paul White (3/18/2010)


    stefan.gustafsson 60897 (3/18/2010)


    The easiest way to fix the problem is to make the index clustered instead of non-clustered. This would definitely solve the problem.

    :blink: You want to create...

  • RE: TSQL using parameters does not use the index

    The easiest way to fix the problem is to make the index clustered instead of non-clustered. This would definitely solve the problem.

    If it for some reason is impossible to change...

Viewing 9 posts - 301 through 309 (of 309 total)