Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
Log in  ::  Register  ::  Not logged in

Articles with tag T-SQL Rss

Search for any content tagged t-sql

<< Newer    Items 21 to 40 of 1131    Older >>

Join Operations – Hash Match

The way in which SQL Server chooses to join your tables in a query can dramatically affect performance. In this article, Jason Brimhall explains how a hash match works and shows some performance numbers.  Read more...
By Jason Brimhall 2014/03/04 | Source: | Category: execution plans
Rating: |  Discuss |   Briefcase | 8,238 reads

Calendar Tables III - Changing Business Rules

The client wants to change a date based business rule  Read more...
By Todd Fifield 2014/02/28 (first published: 2011/02/16) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 12,823 reads


Steve Jones has a problem with the inconsistency of the CREATE TABLE statement in SQL Server and has an idea on what to do.  Read more...
By Steve Jones 2014/02/27 | Source: | Category: editorial
Rating: (not yet rated) |  Discuss |   Briefcase | 231 reads

A Quick Tour of sp_ExecuteSQL

sp_ExecuteSQL can be used to dynamically execute T-SQL code. Learn how to use it and how to add parameters to control what code is executed.  Read more...
By Jonathan Allen 2014/02/24 | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 8,084 reads

Calendar Tables II - The Anchor

Show the results for a date even if there is no data.  Read more...
By Todd Fifield 2014/02/21 (first published: 2010/08/16) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 14,827 reads

Calendar Tables

Learn how to avoid complex date calculations and increase performance using calendar tables in this article from Todd Fifield.  Read more...
By Todd Fifield 2014/02/14 (first published: 2010/07/15) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 38,134 reads

Sending a Variable Number of Elements in a Parameter

What are your options for sending a variable number of choices in a parameter to a stored procedure? Alex Grinberg looks at three techniques you can use.  Read more...
By Alex Grinberg 2014/02/06 | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 8,408 reads

The Performance of the T-SQL Window Functions

Window Functions in SQL greatly simplify a whole range of financial and statistical aggregations on sets of data. Because there is less SQL on the page, it is easy to assume that the performance is better too: but is it? Dwain gets out the test harness to investigate.  Read more...
By Additional Articles 2014/02/06 | Source: SimpleTalk | Category: t-sql
Rating:  Rate this |   Briefcase | 4,001 reads

Finding “Active” Rows for the Previous Month (SQL Spackle)

SQL Server MVP Jeff Moden walks us through the classic problem of finding all the "Active" rows for the previous month using start and end dates. This is excellent for those new to T-SQL.  Read more...
By Jeff Moden 2014/01/30 | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 6,055 reads

Backup to the right location, by default

How do you configure where your database backups are created? Do you have problems updating all of your backup jobs if the backup location needs to change? See how you can make use of Windows settings and a few lines of simple TSQL to have total control over where you database backups are created.   Read more...
By Additional Articles 2014/01/30 | Source: SimpleTalk | Category: backup
Rating:  Rate this |   Briefcase | 2,211 reads

Calculating the Median Value within a Partitioned Set Using T-SQL

It is ironic that one of the most essential of statistical aggregations, the median, has been so difficult in the past to calculate efficiently in SQL. Dwain Camps sets the candidates to work and identifies the winners and losers.   Read more...
By Additional Articles 2014/01/22 | Source: SimpleTalk | Category: median
Rating:  Rate this |   Briefcase | 2,491 reads

Fun with Outer Joins

Learn how an outer join works and how you can use it in your applications to find the results you need when matching data isn't in all your tables.  Read more...
By Kenneth Fisher 2014/01/17 (first published: 2012/09/10) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 21,855 reads

Calculating Duration Using DATETIME Start and End Dates (SQL Spackle)

It's an old problem with a solution that's nearly as old. SQL Server MVP Jeff Moden shows us the old trick mixed with a slick trick to format the duration as extended hours, minutes, seconds, and milliseconds.   Read more...
By Jeff Moden 2014/01/16 | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 10,476 reads

Stairway to T-SQL: Beyond The Basics Level 1: The TOP Clause

The first topic in this stairway will be discussing the TOP clause. The TOP clause allows you to control the number of rows to be returned or affected by a query.  Read more...
By Gregory Larsen 2014/01/15 | Source: | Category: stairway series
Rating: |  Discuss |   Briefcase | 12,404 reads

A Simple Recursion Finds Joins

When you need to find all the related rows and tables to a parent table, here's one way you might approach the problem.   Read more...
By Kate Luxemburg 2014/01/06 | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 8,012 reads

Hidden Formatting Troubles with STR() (SQL Spackle)

Fill in another bit of your T-SQL knowledge about STR(). It right justifies, rounds, and controls the output width of columns. Sounds perfect but here's why you might not want to use it.  Read more...
By Jeff Moden 2014/01/02 (first published: 2010/12/15) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 10,958 reads

Free eBook: 45 Database Performance Tips for Developers

As a developer, if you need to go into the database and write queries, design tables, or determine the configuration of your SQL Server Systems, these tips should help make sure you're not unnecessarily sacrificing database performance. This eBook has 45 easy tips to improve the performance of your indexes and T-SQL queries, and hunt down problems within ORM tools and database design.   Read more...
By Press Release 2014/01/02 (first published: 2013/11/04) | Source: Red-Gate | Category: tips
Rating:  Rate this |   Briefcase | 15,340 reads

How to Compare Rows within Partitioned Sets to Find Overlapping Dates

How to Compare Rows within Partitioned Sets to Find Overlapping, Contiguous, or Gap dates  Read more...
By Kevin Wu 2013/12/25 (first published: 2010/10/11) | Source: | Category: cte
Rating: |  Discuss |   Briefcase | 6,909 reads

Automation: Changing SQL Service Startup Parameters using T-SQL

Quick and efficent way to change SQL service startup parameters for 1000 instances!  Read more...
By Shaunt Khalatian 2013/12/19 | Source: | Category: automation
Rating: |  Discuss |   Briefcase | 2,885 reads

The Zero to N Parameter Problem (Sql Server 2005 and Up -- Update)

This article uses XML to deal with optional parameters along with multiple parameter passed into a stored procedure. (Note: We are re-running this as we had a newsletter issue last week)  Read more...
By Sloan Holliday 2013/12/16 (first published: 2013/12/10) | Source: | Category: t-sql
Rating: |  Discuss |   Briefcase | 7,120 reads
<< Newer    Items 21 to 40 of 1131    Older >>