SSMS Tip: Beep When Query Completes

bell_smI’m old enough to remember when multitasking was considered a good thing. From the same mouths that brought you “work smarter, not harder” came the advice to always be working on multiple things at once to improve efficiency. However, we’ve since learned that deep focus is more serial than parallel, and that trying to focus on multiple things at once actually degrades productivity.

While rapid multitasking isn’t usually a positive, there are times when one must table a task to work on another. As a data geek, I frequently have a need to kick off a query that will run for a while and work on another task while I wait for that query to complete. Ordinarily I would have to keep checking back on the status of the query, but SQL Server Management Studio has a little-used but handy feature that will sound an audible alert when a query completes.

Ring the bell

If you want to enable audible alerts for query completion, open the Tools –> Options window in SSMS. Find the Query Results tab, and select SQL Server. At the bottom of that tab, you’ll see a check box to enable the Windows default beep upon query batch completion. This behavior is disabled by default, but ticking that box will cause an audible alert when any query completes its operation in SQL Server Management Studio.

ssms_beep

The sound played here is simply the default Windows “beep” sound defined in your PC settings. While it would be fun to set up custom tones (or possibly different tones for success and failure), the option is pretty limited here. Still, it’s very handy to have this audible notification, especially if you have a long-running query and you want to cycle your focus elsewhere while you wait for the batch to complete.

When you make this change, it will only apply to new queries opened after the change is made. Any currently open query windows will ignore this change unless you close and reopen the query.

About the Author

Tim Mitchell
Tim Mitchell is a data architect and consultant who specializes in getting rid of data pain points. Need help with data warehousing, ETL, reporting, or training? If so, contact Tim for a no-obligation 30-minute chat.

1 Comment on "SSMS Tip: Beep When Query Completes"

  1. Andrew Notarian | December 12, 2019 at 8:06 am | Reply

    I feel like this was the default in Pre-2000 Query Analyzer where the queries took a while because we all had no RAM back in those days. ALT-TAB to Internet Explorer and read The Onion while the server processes your query 🙂

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.