Viewing 15 posts - 34,426 through 34,440 (of 49,552 total)
Either of the examples I gave you will do that, they are (as written) identical in operation and performance.
My comments to The_SQL_DBA was not related to his use of 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
January 25, 2010 at 12:02 pm
Alvin Ramard (1/25/2010)
It's also posted under another name.Don't OPs know that the speed of the response is inversely porportional to the cube of the number of postings?
Yeah, I caught 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
January 25, 2010 at 10:19 am
Urgent! Urgent! Urgent!
http://www.sqlservercentral.com/Forums/Topic853117-145-1.aspx
Exterminate! Exterminate!
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
January 25, 2010 at 10:08 am
Yes
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
January 25, 2010 at 10:08 am
Why is this urgent? Homework with an upcoming deadline?
Please post table definitions, sample data and desired output. Read this to see the best way to post this to get quick...
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
January 25, 2010 at 10:07 am
Please don't cross post. It just wastes peoples time and fragments replies.
No replies to this thread please. Direct replies to: http://www.sqlservercentral.com/Forums/Topic853117-145-1.aspx
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
January 25, 2010 at 10:06 am
The_SQL_DBA (1/25/2010)
Select Distinct(DG.UserID), DG.UserName
, DG.LastName
, DG.FirstName
From DGUsers DG
where DG.UserID in (select distinct UserId from Orders)
Order by DG.UserID
Huh? That's senseless and worse than the original post.
Firstly, you haven't fixed the 'distinct...
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
January 25, 2010 at 10:04 am
Distinct is not a function, it does not take parameters. What you have written is completely equivalent to this
Select Distinct
DG.UserID
, DG.UserName
, DG.LastName
, (DG.FirstName)
From DGUsers DG
Inner Join Orders O On...
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
January 25, 2010 at 10:02 am
Thread continues - http://www.sqlservercentral.com/Forums/Topic853116-1291-1.aspx
No replies here please.
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
January 25, 2010 at 9:58 am
Full outer join, instead of left outer join, and then the s.customer, s.product, s.description columns need to coalese the current and previous years values
Thusly
COALESCE(s.customer, sa.customer) as Customer, ....
Generally a need...
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
January 25, 2010 at 9:33 am
You can find what filegroup the table is in by querying sys.partitions and sys.data_spaces.
If a table is on a filegroup with multiple files it'll be striped across all the files...
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
January 25, 2010 at 9:22 am
You can also look here for the brief version http://sqlinthewild.co.za/index.php/category/sql-server/execution-plans/ Start with this one http://sqlinthewild.co.za/index.php/2007/08/20/reading-execution-plans/
Don't get too hung up on those costs. They are estimates and there are many things...
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
January 25, 2010 at 9:19 am
Steve Jones - Editor (1/25/2010)
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
January 25, 2010 at 7:53 am
Because you have a table scan on the #emp table. SQL's not using either index on that table.
A table scan reads the entire table (hence it's name). All columns,...
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
January 25, 2010 at 7:14 am
The activation process will confirm that.
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
January 25, 2010 at 6:51 am
Viewing 15 posts - 34,426 through 34,440 (of 49,552 total)