Forum Replies Created

Viewing 15 posts - 36,646 through 36,660 (of 49,552 total)

  • RE: Arithmetic overflow

    sudhanva (9/1/2009)


    Since the column length/type in table is decimal(6,2), i dont want to change the precision and scale.

    The biggest number that you can store in a decimal (6,2) is 9999.99....

    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: Slow performance

    timothyawiseman (9/1/2009)


    Similarly, even if SQL is on a server by itself its apparent performance can be slowed down if there is heavy network traffic at the moment.

    I've seen a SQL...

    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: Are the posted questions getting worse?

    Alvin Ramard (9/1/2009)


    24 Hours of PASS starts today and I did not get a good night's sleep last night. It's gonna be a fun 2 days.

    Starts tomorrow for me,...

    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: ExecPlan: cost is so high but the execution is very fast

    riga1966 (9/1/2009)


    Gila,

    sp_help returns a whole bunch of grids.

    Can I get results as Text?

    Sure, switch output to text rather than grid.

    You can use STATISTICS TIME to see which queries take what...

    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 return ONE child row for each Parent row?

    Cross Apply forces the subquery to be run once per row of the outer query. A simple join with ROW_NUMBER does not. It's very easy to see the performance characteristics...

    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: Are there issues with ONLINE INDEX REBUILD

    wjones21 (9/1/2009)


    It may be overkill but I'm also performing an update stats and an sp_recompile on every table that I'm rebuilding indexes on.

    No need and possibly even harmful. Rebuilding indexes...

    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: Datepart (mm, '01/01/2009') -1

    See this for some tricks on working with datetime values

    http://sqlinthewild.co.za/index.php/2007/11/05/datetime-manipulation/

    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: ExecPlan: cost is so high but the execution is very fast

    Great. Now which of those queries is the slow one?

    From management studio you can script table and you can script indexes. Don't think they can be done as one step....

    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: TOP 150 versus Where Clause

    darth.pathos (9/1/2009)


    As far as the Network Traffic, would this (albeit minimal) increase not have an overall impact on the application, especially as it would appear the developers have written all...

    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: ExecPlan: cost is so high but the execution is very fast

    Only the ones that are execution plans. If you take a quick look at each, it should be easy to see which are execution plans and which are real data.

    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: Datepart (mm, '01/01/2009') -1

    Not datepart, but try dateadd.

    p.s. the way you've written those queries is highly inefficient. By putting a function on the column, you're forcing a table scan, SQL cannot use indexes...

    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: making a primary key

    You may still need some extra locking, depending how you do the insert.

    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: TOP 150 versus Where Clause

    Bytes sent and bytes received is just the network traffic. No indication at all which query is more optimal on the server. To investigate that, use the execution plan 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: Space required to restore a backup

    Rob Goddard (9/1/2009)


    Thanks Gail, I wasn't aware of that at all. Seems like such an principal thing to not know as well! :crazy:

    Nah. It confuses lots of people.

    http://www.sqlskills.com/blogs/paul/2007/10/25/DebunkingACoupleOfMythsAroundFullDatabaseBackups.aspx

    http://www.sqlskills.com/BLOGS/PAUL/post/More-on-how-much-transaction-log-a-full-backup-includes.aspx

    Actually,...

    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: Proper Indexing a table containing 200+ fields for better performance

    From the info that you've given us, all I can suggest is to add indexes to support the queries. If you want more specific help than that, please post 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

Viewing 15 posts - 36,646 through 36,660 (of 49,552 total)