SQL Server 2012 T-SQL at a Glance – OFFSET/FETCHCommented on: 3 years ago
(November 21, 2010)
For 1st puzzle, i think we can use your prev. trick of (select 1) only.. SELECT * from tblNumbers order by (select 1) offset 0 rows FETCH First 1 ROW ONLY;
For 2nd : We can take a...
More about Calculating Concurrent SessionsCommented on: 4 years ago
(November 29, 2009)
Is this logic is correct??? This is my first reply to your blog....
select APP,MAX(cnt) as NoOfSessions from
( select s1.app,s.stime,COUNT(*) as cnt from (select app,starttime as sTime...
Recently, I've been working with a consulting client to help them tame CPU usage. Typically, they're clocking over 20,000 queries and operations per second on their e-commerce SQL Server, but ran into an issue where CPU started spiking up above 90 percent for sustained periods of time....More
What should most database administrators be doing on a regular basis? Here's a comprehensive list from Michael K. Campbell of many of the things DBAs typically do on a daily, weekly, monthly, and yearly basis....More