Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««12345

Compare Dates in an iterative manner for a particular set of records Expand / Collapse
Author
Message
Posted Thursday, November 13, 2008 2:38 PM
SSC-Enthusiastic

SSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-EnthusiasticSSC-Enthusiastic

Group: General Forum Members
Last Login: Monday, August 25, 2014 10:23 AM
Points: 149, Visits: 591
that means that you have a lot "bad" de dates in table. in reality difference probably will be more significant
Post #602414
Posted Thursday, November 13, 2008 2:51 PM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Wednesday, August 13, 2014 6:34 AM
Points: 1,566, Visits: 1,851
No, actually, only 10,000 PersonIds in my test table of 5 million rows (1 million unique PersonIDs) have records that are out of order; that's about 1% of the ids. That also explains the nice lift, because the subselect has far fewer rows for the distinct to operate on.

Note: the subselect finds roughly 20,000 rows, distinct return 10,000 rows.
Post #602425
« Prev Topic | Next Topic »

Add to briefcase «««12345

Permissions Expand / Collapse