Viewing 15 posts - 11,341 through 11,355 (of 18,923 total)
So what are you gonna do Friday night at midnight
?
November 3, 2006 at 12:36 pm
Don't be sorry... we were all there at some point in our career. ![]()
November 3, 2006 at 11:49 am
The convert in the select is very minor because it won't affect the query plan (data access wise). It'll take a few cpu cycles to do the converts, but I...
November 3, 2006 at 10:06 am
Hey Joe, don't you feel like you are talking for nothing sometimes???
Guys, Joe literally wrote the book on SQL, he wrote the ISO standards for SQL. I would strongly suggest...
November 3, 2006 at 9:58 am
Let the application worry about that... unless you have loads of different reports using that query. You could centralize the code. The convert in the select part only shouldn't slow...
November 3, 2006 at 9:45 am
The sliding window was used to do something slightly different but it can be modified for this case. This is untested and from the top of my head :
create...
November 3, 2006 at 8:30 am
Didn't I say that I didn't check the query?!? I was assuming it was giving the correct results but that he needed only one row.
Also I may suggest that you...
November 3, 2006 at 8:23 am
Agreed... but we don't know the froms and tos of the update so we would just be speculating at this point.
Also the sliding window method doesn't have that limitation
November 3, 2006 at 7:51 am
Unoptimized :
SELECT TOP 1 COUNT(EmployeeID), dbo.GetDatePortion(StartTime)
FROM dbo.TimeClock
WHERE StartTime > '2006-10-01' AND startTime < '2006-11-01'
GROUP BY dbo.GetDatePortion(StartTime)
ORDER BY COUNT(EmployeeID) DESC
November 3, 2006 at 7:49 am
Not if you index the column. You can also use the slidding window trick (just search these forums to find it).
Also the idea behind this technic is that you don't...
November 3, 2006 at 6:38 am
Sql server enterprise manager, yourserver / gestion / Sql server agent / jobs
Create a new job. From there just check around and you'll see how to make everything work.
If you...
November 3, 2006 at 6:36 am
Good idea but I don't think that there are any moderators on tis site... other than the owners who mainly maintain the site and post editorials.
November 3, 2006 at 6:33 am
You might also consider adding a waifor in the loop to let other transactions execute on the table.
Depending on the update you need to do and the power of the...
November 2, 2006 at 12:22 pm
Viewing 15 posts - 11,341 through 11,355 (of 18,923 total)