Forum Replies Created

Viewing 15 posts - 44,536 through 44,550 (of 49,552 total)

  • RE: Sp inside Sp gets stale and very slow. Unless I recreate it, when its fast

    Run the sp both ways with the execution plan on. See if there's a big difference in the inner proc's exec plan. You could also use Statistics IO and Statistics...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: straight query faster than SP!?

    Matt Miller (9/11/2008)


    a table variable doesn't accumulate statistics like a regular table does. So - the joining back process is likely using an assumed number of rows on...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: .MDF, .LDF file moving

    Two options.

    1) Detach the database, move the files, reattach the database.

    2) Run an ALTER DATABASE and specify the WITH MOVE clause, take the database offline, move the files, bring the...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: .MDF, .LDF file moving

    Please don't cross post. It just wastes people's time and fragments replies.

    No replies to this thread please. Direct replies to:

    http://www.sqlservercentral.com/Forums/Topic568300-146-1.aspx

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: MS-SQL server 2005 fails to restore

    Please post SQL 2005 questions in the SQL 2005 forums. If you post in SQL 2000 forums, we're going to assume the question has soemthing to do with SQL 2000.

    How...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Having trouble with a query...may be a crosstab issue

    Define 'doesn't seem to be working' please.

    Throws an error?

    Gives unexpected results?

    Spawns a black hole?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Maintenance Job

    Anything in the error log?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Where is the value for the max number of ERRORLOG files stored?

    It's not stored anywhere in SQL. It's in the registry.

    I can't remember offhand where, easiest way to find where is to run profiler and filter the trace based on your...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: amount difference between 2 dats

    Does this work?

    -- first, some setup.

    CREATE TABLE #Amounts (

    SomeDate DATETIME,

    SomeAmount INT

    )

    insert into #Amounts values ('2008/09/01',500)

    insert into #Amounts values ('2008/09/02',1500)

    insert into #Amounts values ('2008/09/03',3500)

    -- Setup finished

    CREATE TABLE #WorkTable (

    RowID...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Nested Cursors

    I believe it shows the result of the last fetch operation that occurred.

    Are you sure nested cursors are required? Want to post the gode here and see if any of...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Trigger

    It's also going to run less than optimally, seeing as there's a cursor in it.

    What's supposed to happen?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: The preceding restore operation did not specify WITH NORECOVERY or WITH STANDBY

    Books Online?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Backups -What point of the backup would be reflected in the restore ?

    Excluding any transactions that were uncommitted at the end of the backup. (They'll be included in the backup file, but will be rolled back during the restore)

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: Want to trace what transactions happend in database during certain time

    You need to decide what you want to audit. There's no automatic way to do it.

    If you want to see all queries executed, that means some form of profiler trace....

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • RE: functions

    Can you post code?

    There are a number of constructs within functions that look good and perform terribly. As an example, if you have a scalar udf (user-defined function) that reads...

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 15 posts - 44,536 through 44,550 (of 49,552 total)