My SQL Server Blog
Informative posts on SQL Server Technology
My SQL Server Blog

Writing JOINs vs Nested Select Queries

I have seen a lot of is queries written without using the JOIN syntax. Instead the developer chose to write the query using an IN clause in the WHERE clause with a SELECT statement; a Nested Query. While many people blame nested queries on developers that don't understand joins, they can actually be beneficial. << MORE >>

Reseed an Identity Column

Sometimes identity columns must be reseeded. A good example is when merging data from a couple of different data sources. There is a DBCC command that makes this task easy. DBCC CHECKIDENT (, RESEED, )<< MORE >>

Selecting a Comma Delimited List with TSQL

Sometimes instead of bringing back a table set of information, a query needs to return a comma delimited list. I have seen some crazy stuff to do this like UDFs and Cursors. There is a really simple way to do this in a select statement though.<< MORE >>

Snapshot Transaction

A new transaction level included in SQL Server 2005 is the snapshot transaction level. Snapshot transactions allow for data consistency without blocking. A Snapshot transaction fits between a dirty read, Read Uncommitted, and the Read Committed level.<< MORE >>

Formatting SubTotal Columns in an SSRS Matrix View

Developers that are new to SSRS might be frustrated with formatting Matrix subtotal columns. Once the data in the Matrix is setup the developer might choose a sub-total for one of the column groups. This makes a gray empty box on the row level which cannot be formatted. Logically, this would be where the formatting would take place.<< MORE >>

SQL Server Dynamic Management Views

One of the greatest features, and in my opinion the one that makes SQL Server a top tier enterprise database, is dynamic management views.<< MORE >>

Correlating PerfMon with Profiler

System monitor or PerfMon is a tool that most DBAs need to become familiar with. Many times Profiler will give information regarding to what is running on the database but can't pinpoint the problem. A new feature of SQL Server 2005 is the ability to correlate Profiler data with PerfMon (System Monitor). << MORE >>

Partitioning Tables part 2

A few days ago, I explained how to partition a table in SQL Server 2005. I also mentioned how moving data is very fast when using partitions. This is because you can swap partitions to other tables without having to move data. All that happens is a pointer to the data is moved. A file partition move is great for archiving data.<< MORE >>

Partitioning Tables

SQL Server 2005 introduced a new feature to improve performance for accessing tables. This feature is the ability to partition a table across many disk arrays. << MORE >>

Technorati

Technorati Profile