SQL Server 2012, Technical, Visual Studio

Visual Studio 2010 and SQL Server 2012 server explorer integration

SQL Server 2012 Express is now available to download from this link.

After downloading it and installing it, I tried to integrate it into an existing project in Visual Studio through the Server Explorer, and got the following issue:

This server version is not supported. Only servers up to Microsoft SQL Server 2008 are supported
This server version is not supported. Only servers up to Microsoft SQL Server 2008 are supported

This is apparently a known issue, and happens when you right click on “Data Connections” in Server Explorer, and chose “Create New SQL Server Database”.

The workaround:

The work around is to create your database using Management Studio (Just the DB, not the actual schema).

Once it has been created, you can then “connect” to the database in Visual Studio’s Server Explorer:

Server Explorer Data Connections Add Connection

This will allow you to connect to the database created in Management Studio without any issues.

If you didn’t change it during installation, your instance name will be “.\SQLEXPRESS”.

 

Visual Studio

Converting a Website to a Web Application in Visual Studio 2010

[youtube http://www.youtube.com/watch?v=oXptokM0v7w]

 

I personally will always chose to create a browser facing web based product as a Web Application in Visual Studio 2010. The main reason being that Web Applications actually create a project file containing all of the configuration details for your application. The other being that you don’t need to set anything up in IIS on your local machine.

I recently inherited a Web Site that needed some changes. It was an asp.net site, and the first thing I did was to convert it to a Web Application, just to at least get that explicit definition of what was in the project from the Project file.

It also makes debugging easier if you need to debug your site from the root of your localhost – IIS Express and Cassini will just run a Web Application on a specific port from the root. Web Sites however will run from a Virtual Directory (e.g. http://localhost/MyWebSite/). Web Sites can be configured to run under a port, but it isn’t a simple process.

And of course the other advantage of having a Project file containing all of your Web Server configuration for debugging is actually stored within a file, that can be kept under source control, and can be shared with others without the need for lengthy debugging instructions.