Forum Replies Created

Viewing 15 posts - 3,841 through 3,855 (of 49,552 total)

  • RE: Insert a suffix to the values

    You need to use an update. Yes, update replaces the value, so make the new value contain the old.

    UPDATE SomeTable

    SET SomeColumn = SomeColumn + 'Another string value'

    btw, this is 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: Help with Extended Events

    chuck.forbes (1/14/2016)


    Looks like it defaults to something called an "event stream".

    Shawn Melton (1/14/2016)


    Will also note though that opening the Live Data Viewer attaches a different target to your session called...

    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: What Maintenance task am I missing?

    Then that's your problem, not the maintenance. With no indexes at all, no clustered index, the table is a heap. Firstly index rebuilds won't touch heaps, second deletes don't deallocate...

    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: Restore system db's on SQL2014 from 2008R2 backup

    As I said,

    GilaMonster (1/13/2016)


    Don't restore system databases from one instance to another, doing so is asking for subtle problems.

    Distribution *is* a system database.

    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: Help with Extended Events

    MAX_DISPATCH_LATENCY=30 SECONDS

    Events don't show up instantly in the live data view. They're not dispatched instantly either. Run your queries, wait a bit (oh and make sure that you started 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: What Maintenance task am I missing?

    What indexes does that table have?

    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: Result set should return all values inspite of a "Where clause"

    sqlnewbie17 (1/14/2016)


    If my result set has a million rows wouldn't a case statement be very slow than a where clause.

    That's pretty immaterial. To do what you want requires a case...

    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: Clustered and NonClustered Index

    er.mayankshukla (1/14/2016)


    But, in what scenario adding clustered index keys in unique non clustered index can be useful since the unique non clustered index has unique column which is easily seekable

    And...

    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: Clustered and NonClustered Index

    This is the reason we don’t include Clustered index columns in Non Clustered indexes because even though you mention clustered index columns as a part of your non-clustered index key...

    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: A weird thing with DBCC CHECKDB

    Go into the maintenance plan and enable logging. You need to see the actual error to fix whatever's wrong.

    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: how to partition a table on multiple columns

    vamshikrishnaeee (8/10/2010)


    If I partition the table with 4 columns then I may get better performance.

    Nope.

    If you're looking for improved performance, don't waste your time fiddling with partitioning. Partitioning is for...

    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: Restore system db's on SQL2014 from 2008R2 backup

    Don't restore system databases from one instance to another, doing so is asking for subtle problems.

    Script the logins, linked servers, config settings, roles, jobs, replication out and use those scripts.

    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: Restore system db's on SQL2014 from 2008R2 backup

    No. Master can't be restored from any other version, and to be honest you shouldn't be moving most system DBs from one server to another. Script their contents, recreate. 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: Insert Trigger with multiple Rows

    Within the trigger, something like

    INSERT INTO AnotherTable

    SELECT <whatever columns needed> FROM inserted;

    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: How to reduce huge CXPACKET & LATCH_EX (ACCESS_METHODS_DATASET_PARENT) wait times?

    Join to sys.dm_exec_requests on sessionID and then CROSS APPLY to sys.dm_exec_sql_text using the sql_handle column in exec_requests. I think the column's there in SQL 2008.

    Alternately if you know there's 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

Viewing 15 posts - 3,841 through 3,855 (of 49,552 total)