Archive for category: SQL

SQL Server DB Engine related musings

TIE Fighters and sys.types: “There’s Too Many of Them!”

19 July, 2010 (08:39) | SQL, T-SQL | By: Mark V

As the Y-Wing pilot in Star Wars: Episode VI – Return of the Jedi proclaimed, sometimes there’s too many of them. He was referring to TIE Fighters during the assault on the second Death Star. I echoed the sentiment while querying the system catalog for a client’s database. I was building the foundation for [...]

My Top Ten Lessons From SQL Saturday #31 Chicago

19 April, 2010 (11:50) | SQL, SQLSaturday | By: Mark V

I attended SQL Saturday Chicago this weekend. I had an awesome time and attended great sessions. While I got something good out of every one of the sessions, I decided to distill the entire experience into a top ten list with some of the highlights.

10. According to Google Maps, the distance from Grand station on [...]

A Hint on Using Indexed Views For Read Performance

13 April, 2010 (13:13) | SQL, T-SQL | By: Mark V

Some time ago, I was on a project in which we implemented a report model. The data was located in several different databases, none of which were very conducive to reporting. The consequence was that the views upon which we based our entities for the model required lots of joins and performed poorly. We decided [...]

Finding Foreign Keys

11 March, 2010 (12:59) | SQL, T-SQL | By: Mark V

No, this is not a new initiative by United States Immigration and Customs Enforcement. I am talking databases.
I recently found myself in a situation where I wanted to find all the tables that referenced a particular table via foreign key relationships. I had heard that relying on the built-in dependency tracking (right-clicking the object in [...]

Saving Indiana Jones (and your SSIS packages) From “Bad Dates”

8 February, 2010 (13:55) | SQL, SSIS | By: Mark V

I have been working on a project modifying the ETL for a data warehouse. The source is a Pervasive database which, through SSIS 2005 packages, populates a SQL Server 2005 data warehouse and associated SSAS 2005 cubes. I encountered an issue which reminded me of a scene in the first Indiana Jones film, Raiders of [...]

Jinkies! Passing MultiValue SSRS Parameters To Stored Procedures

5 January, 2010 (13:08) | SQL, SSRS, T-SQL, XML | By: Mark V

SQL Server Reporting Services provides a great way to allows report users to select more than one value from the available values list in parameters, creating a multivalue parameter.
SSRS dynamically creates a comma separated list of the values selected by the user to pass in to the data source.
Great.
It also dynamically creates [...]