Forum Replies Created

Viewing 15 posts - 47,206 through 47,220 (of 49,552 total)

  • RE: SELECT Statement Question

    zubamark (3/7/2008)


    2. Always put distinct in subquery.

    Don't ever put a distinct in an IN or EXISTS subquery. It's meaningless and may cause SQL to do unnecessary work.

    In terms of 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: newbie help, calling SP from a SP

    The timer is fairly accurate. If you want accurate timings, either use profiler to monitor your queries, or you can run SET STATISTICS TIME ON before you run the query,...

    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: I got burned today at a SQL Server Interview!

    Agreed. If you love the job, the money will follow.

    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: Readahead Pages/Sec

    Check the full scans/sec counter.

    From what I know, read-ahead reads are usually done when a table or index is scanned, and the storage engine fetches pages before they are requested,...

    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: I got burned today at a SQL Server Interview!

    Chris Morris (3/6/2008)


    you can't reach the destination of 'best way' without going through 'first way' *.

    * Except Lynn, Steve, Jeff, Dave, Peso, Gail.....

    Hell, no. The amount of times I...

    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 eliminate KeyLookUp in queryplan

    Perhaps I should have said 'not used in the filters' rather than not in the where clause (since there's no where clause)

    The red highlight is a join to 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: Need to return query result in 0.02 sec

    Loner (3/5/2008)


    God knows who designed this database. But the worst thing is somehow it cannot handle the company has more than 5 million shoppers. The query came back...

    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 eliminate KeyLookUp in queryplan

    The index with ProductID first produces an index scan because ProductID is not one of the columns that are filtered on. A query can use an index seek if 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: Tool for Code review

    A competant DBA. Even the Best Practices anaylser isn't foolproof

    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: Readahead Pages/Sec

    What does your full scans/sec look like?

    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: Varchar(max) problem in SQL server 2005

    I need to confirm this, but I believe it is 'as long as it fits'. Will reseach and confirm or correct later

    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: syntax issue, sql server

    You defined the parameter as VARCHAR without specifying a length. If no length is specified, it it 1 character long, essentially VARCHAR(1)

    So at the point of the if, @inputval =...

    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: Reliably reproducible Fatal error 625

    Looks like a severity 20 error, so there should be more information in the SQL error log and/or the windows event log.

    Check them, see if there's anything useful.

    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: I got burned today at a SQL Server Interview!

    Hehe.

    Recently an architect that I was working with put my title down as Database Overlord in a design doc he was working on. That was 3 weeks ago. We're still...

    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: Query improvement

    Interesting.

    I seem to recall a presentation where one of the devs of the execution engine spoke about collapsing functions (I don't remember the technical name). Maybe ISNULL is one 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

Viewing 15 posts - 47,206 through 47,220 (of 49,552 total)