Passion * Technology * Ruthless Competence

Monday, March 19, 2007

VSTDB, Where Have You Been All My Life?

Honestly, this post started off as a rant entitled "Is it Me, or is DB Development a Pain in the Ass?" about the sorry state of database development tools in Visual Studio. But in searching around on MSDN for information about the built-in "Database Project" type (which could more accurately be called "just a bunch of SQL scripts"), I stumbled across information about the Database Professionals edition of Visual Studio Team System. That's right, I had forgotten that we shipped this late last year.

I short, VSTDB (or whatever the "official" acronym is) is 90% of what I was looking for in a DB dev tool. Sure, it's not perfect, but it's a massive improvement over the previous state of the art.

The primary feature of VSTDB is the ability to "build" your database the same way you build your code. You use lots of small scripts that get compiled together into a model (for lack of a better term) of the database as you've defined it. That model can be deployed to a new database instance or used to update an existing instance. You can also compare that model against an existing database in order to determine what's changed and automatically build update SQL scripts for the DBA's to run in the production environment (since you don't want your developers doing that).

It takes a little getting used to, but the "lots of small scripts" approach has a lot of upside. If you have a table with a primary key, you're supposed to define the primary key, indexes, constraints, triggers, etc. in separate scripts from table creation script. This makes things much easier when you're trying to figure out what's changed in your source control system.

VSTDB has a variety of other cool looking features like data generation and unit testing, but I haven't really dug into them much yet. One thing that VSTDB supports that I wasn't expecting was Service Broker! SQL Management Studio has limited SSB support - if you want to create new SSB objects you have to write the DDL directly. VSTDB requires you to write the SSB DDL also (it makes you write DDL for everything, see below) but it at least has templates for all the SSB object types. Very Cool!

Of course, there are always things that could be improved. The T-SQL editor does syntax highlighting but not IntelliSense. It doesn't support the existing visual database tools like the Table Designer. And while you can build T-SQL stored procs, functions, types, etc, VSTDB doesn't support the development of managed SQLCLR stored procs, et.al. Things to work on for v2, I suppose. 

If you're using VS Team Suite, you can download an add-on that adds VSTDB functionality to your existing VSTS installation. It's only 8MB, so it's definitely the way to go for Team Suite users.

Posted By Harry Pierson at 4:15 PM Pacific Standard Time
Comments are closed.

PDC08

patterns & practices
Summit 2008

Øredev

Change Congress
Recent Bookmarks
Tags .NET Framework (2) ADO.NET (5) Agile (7) AJAX (3) Architecture (284) Guidance (6) Interop (2) Modelling (61) Patterns (7) Process (4) SOA (93) Web Services (5) ASP.NET (24) Battlestar Galactica (3) BI (2) BizTalk (4) Blogging (115) dasBlog (11) Podcasting (4) BPM (1) C# (10) C++ (4) Capitals (5) CardSpace (3) CLR (2) College Football (10) Comedy Central (1) Community (81) Concurrency (6) Consumer Electronics (1) Database (13) Dependency Injection (2) Development (117) C Plus Plus (1) Embedded (5) Lanugages (37) Media (2) P2P (11) Rotor (1) SharePoint (6) SOP (3) DIY (1) DLR (14) Domain Specific Languages (13) Durable Messaging (5) Dynamic Languages (10) Dynamic Silverlight (1) Education (3) Enterprise 2.0 (1) Entertainment (14) ETech (15) F# (51) Functional Programming (17) Game Development (2) Guidance Automation (3) Hardware (8) HawkEye (3) Hockey (29) Home Electronics (1) Home Network (5) Humor (5) IASA (1) Idempotence (3) infrastructure (5) Instrumentation (4) Integration (2) IronPython (27) IronRuby (11) Java (2) Job (3) LINQ (19) Live Mesh (2) Lost (1) Master Data Management (1) Media 2.0 (6) Microsoft (29) MIX06 (2) Mobile Phone (1) Monads (5) Morning Coffee (172) Object Oriented (4) Office (5) Open Source (5) Open Space (2) Operations (3) Other (135) Art (1) Books (1) Family (31) Games (18) General Geekery (26) Home Theater (1) Movies (23) Music (20) Politics (3) Society (1) Sports (37) Working at MSFT (15) Parsing Expression Grammar (16) patterns & practices (2) PDC08 (2) Politics (42) PowerPoint (2) PowerShell (33) Presentation (5) Projects (1) HawkWiki (1) Python (4) Quote of the Day (4) Refactoring (1) Research (2) REST (18) Reuse (5) Robotics (2) Rome (5) Ruby (23) Ruby on Rails (1) Sci-Fi (2) Scripting (4) Security (3) Service Broker (14) SharePoint (2) Silverlight (18) Social Software (1) Software + Services (2) Software Design (1) Software Factories (11) Software Industry (1) Spark (1) SQL Server (2) Stephen Colbert (1) TechEd (7) TechEd06 (1) TechRec League (1) Television (6) Travel (6) Unified Client (1) Unit Testing (4) UX (1) Virtual PC (2) Visual Basic (1) Visual Studio (20) Volta (2) Washington Capitals (34) WCF (31) Web 2.0 (65) Web Services (5) WF (21) Windows Live (23) Xbox (1) Xbox 360 (53) XML (7) XNA (14)
Disclaimer: The information in this weblog is provided "AS IS" with no warranties, and confers no rights. This weblog does not represent the thoughts, intentions, plans or strategies of my employer. It is solely my opinion. Inappropriate comments will be deleted at the authors discretion.