Support for Microsoft Dynamics, Acumatica, and Greentree

« Back to Search

Speed Up your SQL Queries with These Tips & Tricks

Posted by Brad Trevaskis on October 20, 2017

The Crestwood Development staff had a recent team sharing session.  One of the things they went over were some great tips and tricks for SQL that we thought you might enjoy too.

Index-Friendly Operators

If you have indexes in your databases, using index-friendly operators can speed up searching.  Indexes identify what data we really care about in a table, so it looks there first.  If you don’t have indexes, then it has to do an entire table scan.  When using operators to find data, basically, anything that is equality is good to use and will give you quick search results.


Set NoCount On

Another way to speed up queries is to turn off the row counting feature.  If you set the NoCount to On, then it doesn’t require us to keep counts of the rows returned and output them.  So, make sure to SET NOCOUNT ON to disable these messages.

Text Selection

We don’t recommend writing insert statements directly, that’s when we use other tools like integration services.  However, if you are, here’s a time saving tip.

  • Select multiple whole rows
  • Then use Alt+Select to enter code on multiple lines at once

Scrollbar Tricks

In SQL Server Management Studio 2016+, there is a checkbox option to turn on a handy little preview area on the right, called Map Mode.  Additionally, we find it helpful to use a split window too.  That way you can view two sections of the same document at once.

Want more tips like these? Subscribe to our blog and get updates delivered right to your inbox.

Share this:


Add your comment:

Start a Support Ticket

Director of Support

We'll get back to you
within 3 hours

8am-5pm CST | 847-394-8820 ext 7

2015 Support Team Stats


support tickets


tickets solved
same day


closed within
5 business days

Webinars & Events



Dynamics GP 2017 Year-end Training - Madison, WI

Wednesday, December 6, 2017  |  9:00 AM–3:00 PM  |  Free



Dynamics GP 2017 Year-end Training - Farmington Hills, MI

Thursday, December 14, 2017  |  1:00 PM–4:00 PM  |  Free



Dynamics GP 2017 Year-end Training - Maitland, FL

Thursday, December 14, 2017  |  1:00 PM–4:00 PM  |  Free