Forum Replies Created

Viewing 15 posts - 31,606 through 31,620 (of 49,552 total)

  • RE: Truncating multiple trans logs

    Radical idea: Switch the databases to simple recovery and you won't have to manually truncate the logs. Switch Model to simple recovery and any new databases will also be in...

    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: Rebuild Index - Doesnt work the way it should !!

    You asked for the quickest way of doing it.

    The quickest way is to run a rebuild on each index. One rebuild. That's what that command does. It rebuilds each...

    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: Insert into table causing deadlocks?

    STherrien-978820 (7/27/2010)


    I'm not sure how to obtain such a graph.

    Enable traceflag 1222. That will make the SQL engine write a deadlock graph into the error log every time a...

    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: Rebuild Index - Doesnt work the way it should !!

    iqtedar (7/27/2010)


    i think the quickest way to de-frag them would be just drop and recreate the clustered index.

    Nope, that's the slowest way. Do that and you'll be rebuilding every nonclustered...

    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: Rebuild Index - Doesnt work the way it should !!

    It doesn't exactly drop and recreate the index. The old index is read to create the new one, then the old is replaced by the new.

    Dropping a clustered index forces...

    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: Insert Into - Please Please Help Me !

    Instead of putting the ORDER BY on the statement that inserts into BB_HOLB999, you need to put it onto the statement that retrieves from BB_HOLB999. So in the example you...

    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: Data integrity

    I saw that, and , as I said, I think you're going to have to detail the problem a lot more to get meaningful help.

    I thought, when you said 'integrity...

    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: Find Index creation date

    paul wilson-360699 (7/27/2010)


    select name,stats_date(object_id,index_id) as Create_date

    From sys.indexes

    That's the date the statistics were last updated. It'll be any one of:

    Date index was created

    Date index was rebuilt

    Date the auto_update of the 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: Log Shipping continued Support from Microsoft

    I think your colleague should ask the instructor for a reference. I haven't seen any talk along those lines, and there are things log shipping can do that mirroring can't...

    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: Data integrity

    I think you're going to need to detail the problem a lot more for anyone to offer meaningful help.

    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: Invalid subquery does not give error when running as part of main query!

    Marios Philippopoulos (7/27/2010)


    I have the following query:

    select * from table1

    where col1 in (select col1 from table2 where col2 = 123)

    The query returns results and no error.

    Because it's a perfectly...

    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: Data integrity

    You can do something like this to populate the table, though it will only insert rows if CheckDB picks up an error.

    INSERT INTO <TableName> (<ColumnList>)

    EXEC ('DBCC CheckDB (''<Database Name'') With...

    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: undo a sql statement

    scott.pletcher (7/27/2010)


    Yes, you have to change the db recovery mode and do a full backup first (or tell SQL you have done one). Then you can do a 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: Insert Into - Please Please Help Me !

    The only thing that an order by does when used on an insert...select is to set the order of the identity columns (if there is one). If you want an...

    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: undo a sql statement

    scott.pletcher (7/27/2010)


    Software is available that can pull that data from the log. Unfortunately, I think all such software now comes with an up-front $ cost.

    $1000+ last time I checked.

    If...

    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 - 31,606 through 31,620 (of 49,552 total)