SQL server

Debug output in stored procedures

I’m a little miffed that you can only debug stored procedures in VS2005 pro and not in VS2005 standard. The frustrating thing is that you can view, edit and trace in VS2005 standard and the menu item for break points is there but it’s greyed out. Pah I say. This little problem led me to rediscover [...]
Published in SQL server on Sunday, August 19th, 2007

Dynamic sorting for columns that are different data type in a store procedure

I really hate transact SQL. I just want to page some records to display on a webpage and it seems every five minutes I find something new that I have to do in the code to get the thing to work the way I’d expect it to. It just makes me despair. The latest problem I [...]
Published in SQL server on Monday, June 12th, 2006

Changing database and database object owners in SQL Server

I’ve managed to make a bit of a mess of the permissions in an SQL Server database for a personal project that I originally created through my web host’s web interface (before I could locate a copy of Enterprise Manager). One of the things I’m trying to fix at the moment is the user who’s the [...]
Published in SQL server on Sunday, April 9th, 2006

Goodbye enterprise manager!

Another great thing about SqlExpress is it comes with a great management tool that seems to have a much nicer UI than the evil incarnate that is SQL Server 2000’s Enterprise Manager which has all those horrible modal dialogs. The new management tool is set up much like Visual Studio with a tabbed area containing each [...]
Published in SQL server on Monday, March 27th, 2006

Getting SQL Express running on XP

I’ve had Sql Server Express installed on my machine since I installed VS2005 about six months ago, but I’ve never actually been able to get it running. Today I actually managed to get it working on my machine. My problem was I was getting error messages whenever I tried to connect to it. The first error [...]
Published in SQL server on Monday, March 27th, 2006

Prompt SQL: Intellisense for SQL

I just wanted to blog a link to a cool tool that someone posted a link to on the MSWebDev list. It’s called prompt sql and provides an intellisense style dropdown menu to SQL Query analyser and the SQL editors in VS.NET.
Published in SQL server on Wednesday, October 12th, 2005

Useful documentation for apps that use Sql Server

I found a couple of useful bits of documentation for working with Sql Server: The first is a list of valid Connection String keywords. The second is the Microsoft Transact SQL reference.
Published in SQL server on Tuesday, May 3rd, 2005

Saving a single value from a query to a variable in Transact SQL

You wouldn’t believe how difficult this was to find, but it’s easy when you know how.. :) DECLARE @MyVariable int SELECT @MyVariable = MyColumn FROM TABLE;
Published in SQL server on Wednesday, November 3rd, 2004