April 26, 2006

Fast Text Processing in SQL Server

rocessing text or long strings in SQL has never been an easy task. SQL is a powerful language for performing fast operations on data sets, but when it comes to processing text or long strings, it’s usually reduced to a prosaic procedural language. This article shows a few techniques for

Count the Number of Rows in Two Tables Using a Single Query

There are several ways to simply count the number of rows in two tables using single query. select ( select count(*) from Table1 ) + ( select count(*) from Table2 ) as total_rows from my_one_row_table select sum(rows) as total_rows from ( select count(*) as rows from Table1 union all select