Forum Replies Created

Viewing 15 posts - 20,371 through 20,385 (of 22,197 total)

  • RE: OR or IN

    But, do it this way, and the execution time decreases radically. The number of reads is slightly higher though... for whatever that's worth:

    SELECT a.[AddressID],

    ...

  • RE: OR or IN

    Neither one is the very best way to do things, but I took this query and ran it against Adventureworks. The execution plans were identical. Both used Index Seeks. The...

  • RE: UPDATE..FROM doesn't seem to work in SQL 2005!!!!

    Use it all the time, but like this:

    UPDATE Table1

    SET Field2 = b.Field2

    FROM Table1 a

    JOIN Table2 b

    ON a.Field1 = b.Field1

    I don't know that the ANSI standard on the join...

  • RE: Intellisense

    I wasn't entirely happy with it either. Not too to be salesman, but Red Gate's SQL Prompt does everything you're looking for. I'm still planning on using it going forward.

  • RE: Trouble with subquery

    Yikes. If they're teaching you to use the IN clause with a sub-select, time to run. Get them to hire Jeff Moden or one of other people from here to...

  • RE: Stored Procedure creating problem

    You should look into the BOL and check out how to do ANSI standard joins. It'll make your code more readable and can improve performance by limiting data at the...

  • RE: *= VS left outer join

    I strongly recommend against using the old style joins. You really can run into trouble and they're not supported in every instance in SQL Server 2005 & above. See here...

  • RE: A Worthwhile Goal

    If I have to pick only one, I'd go with consistency. Once everything looks and acts similarly (even if poorly), it's much easier to work on the quality and raise...

  • RE: High CPU utilization and query is slow

    I suspect you're also getting recompiles during execution. These will kill performance. You might want to use the KEEPFIXED PLAN hint internally on the queries, but not on the proc...

  • RE: High CPU utilization and query is slow

    Sorry, I must have missed the execution plan earlier.

    These are going to prevent the code from using indexes:

    isnull([@lv_processComparisonDate],[@lv_processCOBdate])<=isnull([MARKET_RISK_DB_US].[publish].[DIM_STRATEGY].[EFCT_END_DT] as [selStrategy].[EFCT_END_DT],'9999-12-31 00:00:00.000'

    Also, based on the fact that there are so many...

  • RE: Performance Tuning meeting

    It only captures events as they occur. Nothing in the past.

  • RE: High CPU utilization and query is slow

    Have you looked at the execution plan for the query? It may not be using indexes appropriately, doing scans, etc. If you have a particular query that's killing performance, check...

  • RE: The SQLServerCentral.com Party - 2008

    Do the gambling laws apply if no one is actually, you know, gambling? Although I guess the prizes at the end for the three highest sets of chips could count,...

  • RE: INSERT QUESTION

    I guess I meant, is this statement just one of a batch of TSQL statements? You may have received the 0 rows affected from another part of the query.

  • RE: Analysing a Profiler Trace

    Is the statement in question a SELECT or an INSERT/UPDATE/DELETE. If the latter, the engine ignores the NOLOCK hint.

    The Mode column will show you what kind of lock you're...

Viewing 15 posts - 20,371 through 20,385 (of 22,197 total)