Scheduling things to Run in SQL Server
A key part of the SQL Server Agent is the ability to schedule jobs. While you can create one schedule for each agent job, frequently with applications like Reporting Services, users use Shared Schedules across multiple jobs. For instance, you can set a schedule to run at 8 am on week days or run every 2 hours or pick from a predefined list of schedules that already exist in the MSDB database. These are very convenient. However, if you choose to use these be sure you are keeping track of what is running for each of these shared schedules. You… Continue reading
Approximate COUNT DISTINCT
We all have written queries that use COUNT DISTINCT to get the unique number of non-NULL values from a table. This process can generate a noticeable performance hit especially for larger tables with millions of rows. Many times, there is no way around this. To help mitigate this overhead SQL Server 2019 introduces us to approximating the distinct count with the new APPROX_COUNT_DISTINCT function. The function approximates the count within a 2% precision to the actual answer at a fraction of the time. Let’s see this in action. In this example, I am using the AdventureworksDW2016CTP3 sample database which you… Continue reading
Challenge Accepted
My life for the last 2 years has been a constant battle of putting out fires with system performance; finally user complaints have moved getting this resolved as my top priority. Let’s see how I tackled the problem… Symptoms: Very High Disk Latency as high as 300,000 milliseconds (ms) is not unusual Average: 900 – … Continue reading Challenge Accepted
This Idera ACE Has Been Busy
This year has been a whirlwind so far, thanks to the Idera ACE program. For those that don’t know what that is … What is an Idera ACE? (According to Idera) “ACEs (Advisors & Community Educators) are active community members who have shown a passion for helping the community and sharing their knowledge. We help the … Continue reading This Idera ACE Has Been Busy