Forum Replies Created

Viewing 15 posts - 316 through 330 (of 5,841 total)

  • RE: Mass associations without looping?

    gvoshol 73146 - Monday, April 10, 2017 5:22 AM

    I think we need more information on what you want to achieve here.

    Eirikur's solution...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Archiving or Moving Data

    I actually like the multiple database notion for such scenarios. With a good naming scheme you can automate the heck out of it, including view (with UNION ALL) modification, data...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Issue with Transactions

    1) Please provide create table statements, INSERTs for sample data, and expected outcomes that cover all logic paths.

    2) Review OUTPUT in Books Online. I didn't read closely, but...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Query using a view as a subquery is failing to apply correct criteria

    drew.allen - Wednesday, April 5, 2017 12:59 PM

    cmerr5705 - Wednesday, April 5, 2017 12:37 PM

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Select first row that changed

    drew.allen - Wednesday, April 5, 2017 10:56 AM

    The approach using MIN will work with the sample data, but it's not clear that...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Query using a view as a subquery is failing to apply correct criteria

    Here's another example from my Common TSQL Mistakes session (originally from Plamen Ratchev):

    Use tempdb
    set nocount on
    go

    IF OBJECT_ID(N'Accounts', N'U') IS NOT NULL
     DROP...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Select first row that changed

    SmackMule - Tuesday, April 4, 2017 6:23 PM

    Hi, all. I have a table (500K rows) with user manager history. Basically, it's a...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Query using a view as a subquery is failing to apply correct criteria

    The optimizer can do (almost) anything it wants with your query as long as boolean and algebraically it still gives the same output or effect. Predicates can be pushed up...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: delete performance Issue

    If you have sufficient memory and poor IO then buffer pool cache could be some of the reason.

    Best is to repeatedly run sp_whoisactive during any long-running processes to...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Solution to avoid TEMP tables and CTE's

    Table variables (oh no!).

    If that oh no was related to not being able to use table variables note that you REALLY shouldn't use them. No statistics means...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Does ReOrg Job change query execution plan?

    SQL-DBA-01 - Friday, March 24, 2017 10:44 AM

    Hi Experts

    I found that suddenly for a procedure the query execution plan changed and it...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Execution Plan Training Suggestions

    SSC.com's own Grant Fritchey wrote the book on the topic, and it is FREE:

    SQL Server Execution Plans, 2nd Ed.

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: insert query takes too long ....

    savibp3 - Thursday, March 23, 2017 9:21 AM

    Grant Fritchey - Thursday, March 23, 2017 9:07 AM

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Update Query Performance

    There is plenty of CPU and Memory when this happens. So...

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

  • RE: Issue with deleting millions of rows of data

    Jeff Moden - Monday, March 20, 2017 12:18 PM

    TheSQLGuru - Monday, March 20, 2017 11:23 AM

    Best,
    Kevin G. Boles
    SQL Server Consultant
    SQL MVP 2007-2012
    TheSQLGuru on googles mail service

Viewing 15 posts - 316 through 330 (of 5,841 total)