Technical Article

Query Hierarchical data Using CTE in T-SQL 2005

In response to Sam Stange's "An old and new way to query Hierarchical data", this script uses the new CTE feature of SQL Server 2005 to display the hierarchical data all at once. I have added a check to prevent infinite loop in case there is a loop in the data (actually, there is one […]

3.67 (3)

You rated this post out of 5. Change rating

2007-04-11 (first published: )

1,430 reads

Technical Article

Function Based Index in T-SQL

To build function based index in SQL Server, you can use indexed view (materialized view) or using a computed column. In this script, I give an exmaple of how to use the computed column to implement a function based index on a table to search through a free formated telephone number column. The basic step […]

5 (3)

You rated this post out of 5. Change rating

2007-04-10 (first published: )

8,639 reads

Blogs

SQL Data Pipelines: The Ultimate Guide to Streamlining Your Data Flow

By

Want to build a data analytics foundation that transforms raw data into valuable business...

Using SQL Compare in Read-Only Databases

By

Recently a customer asked if SQL Compare and SQL Data Compare can be used...

T-SQL Tuesday #179 Roundup: The Data Detective Toolkit

By

Earlier this month, I hosted the monthly T-SQL Tuesday invitation in which I asked,...

Read the latest Blogs

Forums

Date Type ETL Question

By Coffee_&_SQL

I'm not sure that I'm posting this in the right section, so please mods...

Possible oddity in msdb.dbo.backupset

By richardmgreen1

Hi all   I've written a script to keep track of how long backups...

Operand data type varchar is invalid for sum operator

By yrstruly

I have this view [dbo].[Asset Metrics - Client(Rama -Client-Test)], which makes use of multiple...

Visit the forum

Question of the Day

Data Migration Assistant Sources

In the current (Sep 2024) Data Migration Assistant, what are the possible sources for on-premises SQL Server instances?

See possible answers