SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 

Content with tags T-SQL, Common Table Expressions (CTE) Rss

   Items 1 to 20 of 20   
 

Beginning a CTE

By Steve Jones 2016/06/03 | Category: t-sql
Rating: (not yet rated) |  Discuss |   Briefcase | 1,717 reads

Using a Recursive CTE to Generate a List

Learn how to generate lists of column values from multiple rows by grouping and using a recursive CTE. This is a very flexible and easy implementation, compared to using cursors or PIVOT operators.  Read more...
By Svetlana Marinova 2015/06/26 (first published: 2013/07/09) | Source: SQLServerCentral.com | Category: recursive cte
Rating: |  Discuss |   Briefcase | 23,181 reads

Illegal CTEs

By Steve Jones 2015/04/21 | Category: t-sql
Rating: (not yet rated) |  Discuss |   Briefcase | 1,815 reads

The CTE Problem

By Steve Jones 2015/04/09 | Category: t-sql
Rating: (not yet rated) |  Discuss |   Briefcase | 2,415 reads

CTE Syntax

By Steve Jones 2015/03/30 | Category: t-sql
Rating: (not yet rated) |  Discuss |   Briefcase | 2,288 reads

CTE

Rating: (not yet rated) |  Discuss |   Briefcase | 2,135 reads

CTE DML

Rating: (not yet rated) |  Discuss |   Briefcase | 2,074 reads

Duplicate Detection and Management

Inevitably, every DBA is eventually asked to delete, merge, or otherwise report on duplicate data. There are many tools at our disposal to make this task both simple and efficient to complete. Read on for simple steps and examples to effectively deal with duplicate data.  Read more...
By Edward Pollack 2014/04/29 | Source: SQLServerCentral.com | Category: duplicate
Rating: |  Discuss |   Briefcase | 6,454 reads

Using a Recursive CTE to Generate a List

Learn how to generate lists of column values from multiple rows by grouping and using a recursive CTE. This is a very flexible and easy implementation, compared to using cursors or PIVOT operators.  Read more...
By Svetlana Marinova 2015/06/26 (first published: 2013/07/09) | Source: SQLServerCentral.com | Category: recursive cte
Rating: |  Discuss |   Briefcase | 23,181 reads

Pros and cons of six SQL table tools

This article shows how to use 6 SQL table-based tools to solve the same problem, and gives the pros and cons of each.  Read more...
By Andy Owl 2011/12/26 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 8,685 reads

Calculating Stock Returns Using the ROW_NUMBER function and CTEs

In finance, when pricing data isn't available on last day of week, month or year, calculating returns is tricky. This article addresses the issue.   Read more...
Rating: |  Discuss |   Briefcase | 5,494 reads

Introduction to Common Table Expressions

Learn how to use common table expressions to simplify your code. Replace temp tables and correlated subqueries with this cool T-SQL feature.  Read more...
By Kathi Kellenberger 2009/12/08 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 14,781 reads

Data Profiling Column Functional Dependency T-SQL

This article demonstrates Data Profiling Functional Dependency  Read more...
By Ira Whiteside 2009/05/20 | Source: SQLServerCentral.com | Category: data profiling
Rating: |  Discuss |   Briefcase | 3,529 reads

Comparing Stored Procedures, Part 6

Sixth in a series of scripts demonstrating a quantitative comparison between the text of two stored procedures  Read more...
By Jesse McLain 2009/04/15 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 1,377 reads

Power and Deception of CTEs

A performance problem with a CTE based stored procedure, opened the developers eyes to a whole new world  Read more...
By Kev Riley 2008/12/01 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 9,005 reads

Uncommon Table Expressions

This article describes an alternate use of CTEs for functional data processing.  Read more...
By Peter Kierstead 2008/08/11 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 9,324 reads

Recursive Queries using Common Table Expressions (CTE) in SQL Server

The problem arises when the hierarchy level increases as SQL Server is limited to 32 levels of recursion. We need a better way to implement recursive queries in SQL Server 2005. How do we do it?  Read more...
By Additional Articles 2008/07/02 | Source: MSSQLTips.com | Category: t-sql
Rating: (not yet rated)  Rate this |   Briefcase | 5,667 reads

CTE Performance

SQL Server 2005 brings a new feature to T-SQL with Common Table Expressions, which make it possible for more complex subquery expressions than in previous versions. Recursion is a common use and Peter He takes a look at how well these new structures perform.   Read more...
By Peter He 2007/05/08 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 16,758 reads

CTEs and Trees

Some new interresting points about trees and CTE in SQL Server : transforming a tree from auto reference to interval model (nested sets), calculating levels in interval model, creating a view of auto ref from an interval model, hierarchical numbering of items, and more. This article includes more examples based on his previous work.   Read more...
Rating: |  Discuss |   Briefcase | 5,547 reads

CTE Performance

SQL Server 2005 brings a new feature to T-SQL with Common Table Expressions, which make it possible for more complex subquery expressions than in previous versions. Recursion is a common use and Peter He takes a look at how well these new structures perform.   Read more...
By Peter He 2007/05/08 | Source: SQLServerCentral.com | Category: t-sql
Rating: |  Discuss |   Briefcase | 16,758 reads
   Items 1 to 20 of 20   
 
Tags
cte (3)    
advanced querying (1)    
correlated subqueries (1)    
data profiling (1)    
derived table (1)    
duplicate (1)    
functional dependency (1)    
merge (1)    
mstvf (1)    
programming (1)    
recursion (1)    
recursive cte (1)    
recursive function (1)    
row_number() (1)    
table variables (1)    
table-valued function (1)    
temp tables (1)