SQL Server Express Edition and Dynamic Ports

by Jon Davis 17. May 2009 14:13

While transferring to my new web host, I ran into a roadblock that had me stalled for a day or two while I tried to figure out what was going wrong. I like to use my own laptop here at home when managing SQL stuff, so I poked a special hole in the Windows Firewall on my new VPS instance to just allow my IP on port 1433, while enabling TCP/IP for SQL Server and restarting the service. But I could not connect!

I spent several hours poking at it, rebooting it, turning off the Windows firewall completely (temporarily), trying to get connected to that darn SQL Server instance I had installed on my new VPS, but it just would not connect. Then I noticed that the client tools (namely SSMS) on the VPS itself could not connect to ITSELF on the TCP/IP stack, it could only connect on Shared Memory or Named Pipes. What is going on?!! Could it be a bad OS image on the VPS?

Eventually it got resolved. The VPS hosting company was very helpful in assisting me on the matter, and at the same time I got some replies on a SQLServerCentral.com forum post that narrowed down to the same problem: Dynamic Ports.

This SQLServerCentral.com forum reply was the critical new knowledge for this weekend.

Hello Jon,

SQL Server Express (2005 & 2008) defaults to Dynamic Ports, whereas the Default Instance of other Editions listen on Static Port 1433 (by default). 

Having a Zero in the Dynamic Port configuration will have been overriding the Static Port that you entered, and therefore causing your connection problems.


John Marsh 

I'd never heard of dynamic ports before. And the reason why I've never run into this issue before was because I've always used the full version of SQL Server that comes with MSDN licenses, and that version, by default, does not use dynamic ports by default, it uses Port 1433, which I expected SQL Server to default to in my case. But for both SQL Server 2005 and SQL Server 2008, the Express edition defaults to use Dynamic Ports when TCP/IP connections are enabled. So all my setting of Port 1433 in the Configuration Manager was completely ignored because it switched right back over to Dynamic Ports. To make things even more confusing, to enable Dynamic Ports, the setting is set to '0'. That's '0', as in the programmatic standard for FALSE, just not in this case, as is thoroughly documented in SQL Server documentation. Heh heh.

So with the Dynamic Ports' setting of '0' removed, I'm up and running. And now this blog (not to mention other, more legitimate sites I run [sic?]) is finally (as of Sunday afternoon) moved off my home PC and onto my new VPS.

SQL Server 2008: Ctrl-Shift-M

by Jon Davis 13. November 2008 14:59

When creating a new stored procedure in SQL Server Management Studio, the sproc template would generate:


	-- Use the Specify Values for Template Parameters
	-- command (Ctrl-Shift-M) to fill in the paramter
	-- values below.


Unfortunately, while the same template is used in SQL Server Management Studio for SQL Server 2008, Ctrl-Shift-M wasn't implemented.

The one-time fix is rather trivial:

  • Tools -> Options -> Environment -> Keyboard
  • Under Keyboard scheme, choose SQL Server 2000.
  • Click OK
  • Go back, .. Tools -> Options -> Environment -> Keyboard
  • Under Keyboard scheme, choose Standard.

This info was found here: http://www.eggheadcafe.com/software/aspnet/32965600/ssms-2008-ctrlshiftm.aspx

How To Get SQL Server 2005 Express In The Midst Of The SQL Server 2008 Express Push

by Jon Davis 13. August 2008 20:10

So, Microsoft went gold with SQL Server 2008, including the core engine flavor (but no basic management studio) of the Express edition. Horray!

Problem is, Visual Studio 2008's database development project support is built entirely around SQL Server 2005 Express, not SQL Server 2008 Express, and I for one made the mistake of dropping SQL Server 2005 Express to install SQL Server 2008 Express and hoped that there was sufficient compatibility to keep my database projects supported. Not so.

So I had to go back to v2005, but now the problem was that there was NO LINK on Microsoft's web site to get back to SQL Server 2005 Express.

I had to rely on Google to acquire this:


Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


T-SQL: Universal User Map

by Jon Davis 23. July 2008 21:20

Here's an approach I recently took with taking a reusable data component that has user identification bindings associated with the data, and making it pluggable to different applications.

There can be lots of different web application databases that involve users, and as such there are often many different ways of identifying them. The primary keys might be:

  • int - The int is fine, it's easy (i.e. terse) to administer, it scales well (so long as you don't have more than a couple billion people hammering on your site). One of the biggest problems with int is that collisions between two applications using int are guaranteed.
  • uniqueidentifier / GUID - This is almost always a value that is guaranteed to be unique between two distinct applications. Unfortunately, almost always and always aren't the same thing; once in a blue moon, collisions do occur. Furthermore, uniqueidentifiers don't scale well -- they're bulky, wordy to administer, and, being somewhat randomly generated, they don't sort in the index in a meaningful way.
  • Email / varchar(xx) - Email is an okay key, it kind of imposes a business rule of social distinction on top of record distinction, which may or may not be appropriate. I think Email is an important column to index--and IMO it's almost always appropriate to use with user credentials as an alternate username on the same login form--but I don't think it's an administrator's ideal as a PK.
  • Username / varchar(xx) - The username is fine for logging in with, but I rarely see it used for primary keys. One problem is that unless you re-index in upper/lower case, you're imposing distinction on case sensitive names, which is not normal practice.

Others might be used but these are used quite often, in that order.

So the problem I ran into was that I was building this "sub-application" that multiple web applications could use, but each web application that would use it handled user IDs differently. First I built the data round uniqueidentifier, since that is most likely to be unique across apps, but then I started asking around about what the applications are actually using. While one does use GUIDs, another uses int, and another uses a mixed choice of GUID, int, and e-mail.

This had me thinking, and so I devised a UserMap table that would accept any combination of any identifying data.

To start with, I already had web application context tables created.

CREATE TABLE [dbo].[Site]
    [CreateDate] datetime NOT NULL CONSTRAINT [DF_Site_CreateDate]  DEFAULT (getdate()),
    [ModifyDate] datetime NOT NULL CONSTRAINT [DF_Site_ModifyDate]  DEFAULT (getdate()),
    BaseUrl nvarchar(500) NOT NULL

CREATE TABLE [dbo].[AppContext]
    [SiteId] [int] NOT NULL,
    [AppContextId] [int] NOT NULL,
    [CreateDate] datetime NOT NULL CONSTRAINT [DF_AppContext_CreateDate]  DEFAULT (getdate()),
    [ModifyDate] datetime NOT NULL CONSTRAINT [DF_AppContext_ModifyDate]  DEFAULT (getdate()),
    [BaseUrl] [nvarchar](500) NOT NULL,
        [SiteId] ASC,
        [AppContextId] ASC

All users are associated with an application context, which is hosted on a site. I don't know anything about the site, the application, or the user, except that a) the site has a URL, 2) the web app has a relative URL, and 3) the user is going to be identified in some way. I don't know what way that will be, I don't care, but I'll guess it'll be one of the fields I listed at the top of this article.

CREATE TABLE [dbo].[UserMap]
    [CreateDate] [datetime] NOT NULL CONSTRAINT [DF_UserMap_CreateDate]  DEFAULT (getdate()),
    [ModifyDate] [datetime] NOT NULL CONSTRAINT [DF_UserMap_ModifyDate]  DEFAULT (getdate()),
    [Guid] uniqueidentifier NOT NULL DEFAULT (newid()),
    [SiteId] int NULL,
    [AppContextId] int NULL,
    [Email] nvarchar(50) NULL,
    [Username] nvarchar(50) NULL,
    [AppUserId] int NULL 

Note that I could also put indexes on each of the identifying columns as well. These indexes will slow INSERTs and UPDATEs down, but SELECTs will be very fast. Given that this particular application add-on I'm building is intended to be used for data collection more than anything else, I will not add these indexes.

Because this table stores multiple different kinds of identifying information, each web application can now perform a JOIN operation against this table in whatever way it deems appropriate, as long as it includes the SiteId and AppContextId in the JOIN clause.

So now when working with my data tables, I would only store the sub-app's UserId. Now I needed my INSERTing stored procedures to look that ID up, and in its absence, to INSERT the mapping record. I also needed to enforce the rule that some kind of identification is mandatory for insertion. I didn't implement a constraint, but I did implement a few stored procedures that imposed this rule.

Let's look at the first problem. I want to INSERT some data in some other table, using only a UserId. I don't know what the UserId is, but I do have an e-mail address, or a username, or a GUID, or something.

Well, how about if I just do a lookup?

CREATE PROCEDURE [dbo].[UserMap_GetUserId]
    @SiteId int,
    @AppContextId int,
    @UserGuid uniqueidentifier = NULL,
    @AppUserId int = NULL,
    @UserEmail varchar(50) = NULL,
    @AppUsername varchar(50) = NULL,
    @UserId int output
    DECLARE @sql nvarchar(max)
    SET @sql = N'SELECT @UserId = (SELECT TOP 1 [UserId] FROM [dbo].[UserMap] '
        + N'WHERE SiteId=' + CONVERT(varchar(10), @SiteId)
        + N'  AND AppContextId=' + CONVERT(varchar(10), @AppContextId) + N' AND'
    IF @AppUserId    IS NOT NULL SET @sql = @sql + N' [AppUserId]    = ' +  CONVERT(nvarchar(10), @AppUserId) + N' AND'
    IF @UserGuid    IS NOT NULL SET @sql = @sql + N' [Guid]        = N''' + CONVERT(nvarchar(50), @UserGuid) + N''' AND'
    IF @UserEmail    IS NOT NULL SET @sql = @sql + N' [Email]        = N''' + CONVERT(nvarchar(50), @UserEmail) + N''' AND'
    IF @AppUsername    IS NOT NULL SET @sql = @sql + N' [Username]    = N''' + CONVERT(nvarchar(50), @AppUsername) + N''' AND'
    SET @sql = SUBSTRING(@sql, 1, LEN(@sql)-4) + N')'
    print @sql
    EXEC sp_executesql @sql, N'@UserId int output', @UserId output
    return @UserId


Notice that it doesn't create the UserId if no records are returned. This is an exported sproc that actually gets used on the INSERT sprocs for the other tables.

CREATE PROCEDURE [dbo].[MyAppData_Add_GetNewID]
    @MyAppContextId int,
    @MyAppFieldId int,
    @UserId int = NULL,
    @AppUserId int = NULL,
    @UserGuid uniqueidentifier = NULL,
    @UserEmail varchar(50) = NULL,
    @AppUsername varchar(50) = NULL,
    @DataText varchar(500),
    @MyAppFieldOptionId int,
    @MyAppDataId int output
    DECLARE @CreateDate datetime, @ModifyDate datetime
    SET @CreateDate = getdate()
    SET @ModifyDate = @CreateDate
    DECLARE @MyAppId int
    DECLARE @SiteId int
    DECLARE @AppContextId int

    SELECT @SiteId = [SiteId], @AppContextId = [AppContextId], @MyAppId = [MyAppId]
    FROM [MyAppContext]
    WHERE [MyAppContextId] = @MyAppContextId
    IF @UserId IS NULL  
        IF @AppUserId IS NOT NULL
        OR @UserGuid IS NOT NULL
        OR @UserEmail IS NOT NULL
        OR @AppUsername IS NOT NULL
            EXEC [dbo].[UserMap_GetUserId] @UserGuid, @AppUserId, @UserEmail, @AppUsername, @UserId output
            RAISERROR ('Must populate a user identification field.', 16, 1)
    IF @UserId IS NULL --still, perhaps due to provided data but no match
        print '@UserId is still null.'
        EXEC [dbo].[UserMap_Add_GetNewID] @SiteId, @AppContextId, @AppUserId, @UserGuid, @UserEmail, @AppUsername, @UserId output

    INSERT INTO [dbo].[MyAppData]
    ) VALUES (
    return @MyAppDataId; 

Now notice that if it's still null, it's invoking [dbo].[UserMap_Add_GetNewID], which is basically the INSERT sproc for the user map table. Here that is below, and note that it does a simple INSERT and then a dynamic UPDATE. I only did this for simplicity's sake, to minimize the code, I don't think it will make a huge difference performance-wise.

CREATE PROCEDURE [dbo].[UserMap_Add_GetNewID]
    @SiteId int,
    @AppContextId int,
    @AppUserId int,
    @UserGuid uniqueidentifier = NULL,
    @Email varchar(50) = NULL,
    @Username varchar(50) = NULL,
    @UserId int output
    INSERT INTO [dbo].[UserMap]
    ) VALUES (
    EXEC [dbo].[UserMap_Update] @UserId, @SiteId, @AppContextId, @AppUserId, @UserGuid, @Email, @Username
    return @UserId;
CREATE PROCEDURE [dbo].[UserMap_Update]
    @UserId int,
    @SiteId int,
    @AppContextId int,
    @AppUserId int,
    @UserGuid uniqueidentifier = NULL,
    @Email varchar(50) = NULL,
    @Username varchar(50) = NULL
    DECLARE @sql nvarchar(max)
    SET @sql = N'UPDATE [dbo].[UserMap] SET [SiteId] = ' +  CONVERT(varchar(10), @SiteId) + ', '
        + N'[AppContextId] = ' + CONVERT(varchar(10), @AppContextId) + N','
        + N'[ModifyDate] = getdate(),'
    IF @AppUserId    IS NOT NULL SET @sql = @sql + N' [AppUserId]    = ' +  CONVERT(varchar(10), @AppUserId) + N','
    IF @UserGuid    IS NOT NULL SET @sql = @sql + N' [Guid]        = N''' + CONVERT(varchar(50), @UserGuid) + N''','
    IF @Email        IS NOT NULL SET @sql = @sql + N' [Email]        = N''' + CONVERT(varchar(50), @Email) + N''','
    IF @Username    IS NOT NULL SET @sql = @sql + N' [Username]    = N''' + CONVERT(varchar(50), @Username) + N''','
    SET @sql = SUBSTRING(@sql, 1, LEN(@sql)-1) + N' WHERE [UserId]    = ' + CONVERT(varchar(50), @UserId)

That's it. I came up with it and implemented and tested in one late afternoon, I feel good about it, but I'm open to feedback. Does it smell bad? Am I doing something bad here? T-SQL isn't my greatest strength so fill me in.

kick it on DotNetKicks.com

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: , , ,

Lists Of Microsoft's Fame And Shame - 2008

by Jon Davis 5. April 2008 20:44

Since everyone loves to pick on Microsoft, I think we can summarize exactly what has caused such a commotion among technology enthusiasts. The areas where Microsoft has been given most reputational grief have been where the bar was raised higher by a third party, or else where a third party has made people scratch their heads and wonder, "Why am I using Microsoft's technology, anyway?" So I'd like to suggest a list of technologies that shame Microsoft.

To Microsoft's Fame

Before I get started, I want to point out the areas that Microsoft has excelled in:

  1. Microsoft Word & Microsoft Outlook
    • Word processing has become a staple of the computing world. Apart from web browsing and e-mail, the word processor is the next most important and relevant "killer app" of computing technology. Microsoft Word continues to astound us with major new features with every release. It has evolved in sophistication regularly. It is not without its quirks -- for example, there's nothing more annoying than running out of callout diagram graphics due to fixed memory allocation -- but Microsoft has consistently tried to keep Word up-to-date with the demands of its users, and no other word processor can compare with its overall user experience.
    • Microsoft Outlook might feel a little sluggish for some, and I still resent the fact that Microsoft never implemented NNTP support within Microsoft Outlook, but it is still the ultimate app for the office. Maintaining e-mails, calendaring, and task lists in one application, it is always the first app to run when I get in at work, and the last app to close, if I ever close it. And it gets the most attention every day.
      • Microsoft Outlook's greatest area for growth is project management support. Outlook would be a natural environment for managing projects. If the communications and collaboration environment that Outlook already is was consolidated with issue tracking, resource allocation (perhaps merge with MS Project), and even basic SCRUM, professionals would be flocking to the platform all over again. There's always Sharepoint for team collaboration, but Outlook being a desktop application with tuned responsiveness, it blows any AJAX web application out of the water (and please don't even think Silverlight, with its lack of OLE integration, limited [or no] drag-and-drop, limited contextual menu support, and no windowing support). I think Microsoft has regularly missed opportunities to make Outlook the ultimate "portal" for all things related to collaboration.
  2. Visual Studio, .NET, and C# - http://msdn.microsoft.com/
    • A few years ago I sent a big gripe e-mail to one of Apple's feedback e-mail addresses. It said something along the lines of, "You guys just don't get it. There's a really good reason why more apps are written for Windows rather than for the Mac, and it isn't because Windows is superior. It's because Microsoft pours boatloads of its money into developer support. The MSDN program is probably more important for Microsoft than Windows itself. The return on investment that Microsoft gets with all of its investments with development tools is a no-brainer. If you guys would establish a 'developer network', provide refined developer tools, and make being a Mac developer one of the most exciting and rewarding things about your technology, people would be flocking to your platform." I still believe that this is true. Ironically, a few months after that e-mail there was a huge developer tools push by Apple. Heh..
    • Visual Studio and the core Microsoft SDKs blow all of the competitors, even the latest and greatest iterations of IDEs like Eclipse and NetBeans, completely out of the water. Don't get me wrong, I love what I see in focused IDEs like Aptana. But as a do-it-all toolset, Visual Studio 2008 is just insane. I actually don't think there's anything, except for easy COM object development (*sob* I still miss VB6), that Visual Studio can't do. C# (which is Microsoft's invention and part of the Visual Studio and MSDN strategies) is an incredibly elegant language, even more so than Java, and that's saying a lot because Java as a language was very nice. Using Visual Studio for web development is also very rewarding; I work with it every day.
      • Microsoft is doing something very right with CodePlex and Microsoft's open source initiatives. However, I think that Microsoft should put the plug back in on their idea that they prototyped during the VS 2005 beta of community-generated libraries directly integrated in a community browser. This is a huge feature of Eclipse and NetBeans alike, and if we could get our third party open source Visual Studio plug-ins and API libraries from a common interface it would be quite ideal for the developer community. Perhaps an open source initiative can be established for this.
    • I'm still not quite sold on WPF because of its bloat, and Silverlight 2 is still pretty painfully stripped-down, but what it does introduce is very, very exciting. Adobe Flash would have easily become a product technology to shame Microsoft, but when it comes to what Silverlight 2 and Blend 2.5 promise and are already delivering in beta form, Microsoft has taken the higher ground. Granted, Flash has the user base. But being a geek, I don't care; I firmly believe that the user base will follow the superior toolset.
      • I think that Microsoft still needs to implement a few things before Silverlight will really become a "killer app" technology platform, keeping in mind that for every Flash-based banner ad or RIA, there is a Flash game being introduced on the web:
        1. Limited windowing support. Please. I want to open a Silverlight window, without opening a web browser window with another isolated Silvelight app. Let me. 
        2. GDI+-esque bitmap manipulation support. For example, we should be able to render to a canvas, buffer to a bitmap, and reuse the bitmap as we like. Let us render pixels. I don't know what kind of installation footprint a rasterization API would introduce, but it seems like it would be pretty light.
        3. WPF-esque 3D support by befriending OpenGL. Please. Every platform supports OGL. EVERY PLATFORM!
    • DirectX is the responsible runtime API for, what, 90% of modern commercial electronic games today? At least, that is certainly accurate of PC games. Direct3D is feature-rich, setting the bar for the programmability of a video card's GPU (using a Shader Model programming API), to say nothing of supporting a complete set of interfaces for generating 2D and 3D scenes with lighting and high resolution textures. XACT offers a complete audio API and toolset, after years of one tool experiment after another for audio and music. DirectX also has networking APIs and input device APIs (flight sticks, gamepads, steering wheels, etc.). All your game engine needs are met with DirectX ... except for the game engine itself. That's where XNA comes in.
    • Direct3D is clearly superior in featureset than OpenGL.
    • DirectX as a suite of APIs specifically targeting Windows is vastly superior to SDL.
    • While I still scratch my head wondering why XNA and WPF are so completely isolated, and that there is neither XAML rendering support in XNA nor XNA features in WPF, I am very impressed with Microsoft's XNA. XNA had a warm welcome to the community in 2007, I feel. But XNA was quickly forgotten by the general developer community by the end of 2007, until XNA Game Studio Express v2.0 was released.
      • Microsoft's XNA strategy has been very thorough, with the Creators Club web site completing the big picture. But what Microsoft still needs to do with XNA to continue to gain and retain amateur game developers and establish the "YouTube For Games" community that it intends to foster is to convince developers to deploy Windows game install packages today, and to feature XNA games on Windows before the roll out XNA games on Xbox Live Marketplace. Microsoft should create a web service driven "XNA Amateur Games Browser" for Windows, now! It should be an optional Windows Update download for Windows Vista Ultimate. Microsoft has really blown it in gaining and retaining amateur game developers' attention on the Microsoft Windows platform. XNA has been a missed opportunity; the technology and toolset are solid, but XNA is till marketed, intentionally or not, as an Xbox technology that requires $99 to participate in, which is tragic. Most game developers would opt for spending that kind of money on such cross-platform technologies as Torque and Unity (http://unity3d.com/). Microsoft XNA needs an InstantAction-like community before it seeks out the Xbox Live Marketplace community.
  3. Windows Server 2008
    • In some ways, Window Server 2008 represents the culmination of all things heavily tested, refined, tuned, and applicable for both simple and complex scenarios and for executing both simple and complex computing applications. It compares quite closely with Mac OS X. Mac OS X, being built on a UNIX foundation, comes straight out of the box with the rich featureset of UNIX network and system tools, to say nothing of its extensibility to support additional UNIX apps that can run naturally and stably on it. But not only does Windows Server 2008 support all of the essentials of an operating system workstation as well as an IT server, it also has a UNIX compatibility subsystem, and on top of that it sets a MUCH higher bar in many areas of server technology that currently other platforms simply do not support. Just browsing the optional features one can install onto Windows Server straight out of the box, suddenly even the beta-quality grab bag of nifty new technologies one can choose in a modern Linux distro is not able to compare, even in features alone.
    • Not long ago, I posted a blog entry indicating that I'd prefer Windows Vista Ultimate SP1 over Windows Server 2008 as a web developer workstation. I think I may have to retract that opinion. Other people have posted performance comparisons of these two operating systems and have found that Windows Server 2008 performs significantly better than Vista SP1. This is very disappointing as I love Vista and was very much looking forward to SP1 picking up he pace to be on par with Windows Server 2008. 
      • I have three workstation-related complaints for Windows Server 2008, based on my watching my co-worker's / buddy's experiences with using it as a workstation:
        1. No sidebar even with Vista experience installed?!
        2. COD 4 BSOD's on Windows Server 2008 on an nVidia Quadro 1500 card that worked fine for me on Windows Server 2003, as well as for me on Vista x86 and on Vista x64. Sup widdat?
        3. What's with that awful addressbar/progressbar locking up Windows Explorer functionality just because the OS is (I guess) indexing system contents?? My buddy couldn't even right-click a folder and view Properties at times because of this stupid indexing lock-up. This went on for a month or so before it apparently went away on its own, we figured it finally managed to index everything, or something. But this one thing kept me from making the switch from Server 2003!! 
  4. IIS 7.0 & WCF
    • IIS is now fully programmable on all parts of a request pipeline, even at the protocol level (IIS is no longer a web server, it is a network application server).
    • Microsoft has taken their experiences of the nightmares that came about with COM/DCOM/COM+, MTS, .NET 1.x Remoting, and ASP.NET Web Services, and made a simple yet pretty complete solution for it all. As long as you code all your software around data contracts, you have WCF-handshakeable, interopable software that can cross most any boundary. Hosted on IIS 7, said software can cross any physical boundary.

To Microsoft's Shame

These things said, here's a list of technologies and third party products where I think Microsoft should be paying closer attention as they bring shame upon Microsoft.

    • When Scott Guthrie came here to Scottsdale (that's where I live) this year, Hamid Shojaee from Axosoft did a little presentation for his company's products, and he used presentation software that kept me blinking in awe. Although judging from the presentation the presentation software he used looked like it was pretty lightweight in features (I found out later it was Keynote for Mac), based on Hamid's presentation Keynote had one thing that made me realize that Microsoft is going about its PowerPoint strategy all wrong. I realized that rock-solid, eye-catching presentations are all about being flicker-free, with full 3D fly-ins and no visible pause between tween frames. I noticed this about Silverlight; when I look at http://www.quiksilver-europe.com/ and hover my mouse over the video player, I see something that Flash can't do, which is look frame-free and flicker-free because its animation engine is time-based, not frame-based. Between WPF and Silverlight, Microsoft already has the technology to support all this. If the next version of PowerPoint is not overhauled to look this smooth, Microsoft should be ashamed of themselves!
  1. Firefox and Webkit (TIE)
    • Once upon a time, Microsoft innovated in the web browser technology market. They introduced a powerful software plug-in model with ActiveX and pushed it out on Internet scale. They invented the fully programmable HTML DOM.
    • Eventually,
      • C# was introduced.
      • Firefox came on the scene.
      • George W. Bush was elected president.
      • Microsoft got complacent about their web browser strategy, and made it official that they would never innovate on the browser again.
    • The effects of Microsoft taking their genius Internet Explorer innovations staff (the Trident team) off of Internet Explorer and onto WPF and Silverlight has taken its toll. As web technology has evolved, Internet Explorer has become the uber-pimple of the computing world. It's the annoying, ugly blemish that people want to pinch and pop but not only won't go away but it's right out there for everyone to see on the face of Windows and you can't get rid of it. It has a slow release schedule, its dev team has been silent towards the community, and it is clearly not a part of Microsoft's MSDN strategy, yet at the same time it is one of the most prominent and heavily used development platforms that runs on Windows. I'm greatly looking forward to IE8, but Microsoft is still playing catch-up with the other browsers.
    • Microsoft has a lot of nerve to suggest that the different meanings of the word standards ("standard as in popularity? standard as in typical? standard as in standards-body documented standard?") are applicable to web technology. If you're going to put yourself out there on the web and interoperate with a platform-agnostic network, to the extent of those agnostic technologies (HTML, XHTML, CSS, Javascript, etc.) there is only one definition of standards, and that is the definition of standards that comes from the international standards bodies, in this case the W3C. Microsoft can do what they want with XAML, VBScript, and ActiveX, but if they're not going to submit to standards bodies on platform-agnostic technologies, they should drop IE and adopt Firefox or WebKit, or else they will risk their users doing as much which in effect would significantly lessen the necessity of Windows (the necessary host operating system of IE).
    • Mozilla, Safari, and Opera leaders are actively leading in innovating on the web standards, like HTML 5, a practice that Microsoft started in the early days of the web, and later abandoned. Microsoft is still not actively participating in these discussions.
    • XPCOM and XPI! Make it so!!
    • Earlier in this blog post I mentioned Windows Server 2008 being most like Mac OS X. But Mac OS X still sets certain standards for the Ultimate Operating System. Granted, Windows Vista and/or Windows Server 2008 is still the OS of choice for practical use because of the rich developer tools that Microsoft offers and because of the extent of third party apps that are available because of it. But Mac OS X still sets the bar for
      1. True "it just works" plug-and-play functionality. I don't know what Apple is doing to make things "just work", but all of the iterations of the Mac have always been rediculously clean and easy to use, for both hardware add-ons and software installations.
      2. Application packaging; Mac apps continue the trend today that they've always had, of getting both Apple apps and third party apps (except MS Office for Mac) all presenting themselves as a nicely packaged, self-contained file, rather than a gajillion DLLs among one or several shell-executable files. Mac users don't use a Start menu because they don't need one.
      3. Platform interopability. Virtualization is not platform interop. Microsoft's UNIX compatibility layer is a step in the right direction, but it isn't enough. Windows is still proprietary Windows; UNIX apps have to be re-compiled to work on the UNIX compatibility layer, and for that one might as well use Cygwin which is far easier and "funner" to use (which isn't saying it's fun). A more appropriate approach might be andLinux.org's.
      4. With Mac OS X's UNIX based core, the rich suite of well-established UNIX applications are at OS X's disposal, including Apache Web Server. Apache in itself is not all that astounding in contrast to IIS, but it is one little tool in a long list of applications that make any non-Windows computer user compelled to stick with the Mac.
      5. The new file browsing features in the latest version of the Mac that put Windows Vista's thumbnail and slide show views to shame are absolutely astounding.
      6. The new video conferencing features in the latest version of the Mac are also astounding. Windows doesn't have anything like that.
    • I've said it before, and I'll say it again: The Start menu on a mobile device is perhaps the suckiest, stupidest design idea ever invented and implemented in mainstream technology. To the same extent, though, the iPhone's multi-touch, naturalistic, responsive interface is perhaps the greatest interface design ever conceived and implemented in mainstream technology. The bar has been set about 3 times higher than it was; now Microsoft needs to measure up with its Windows Mobile strategy, and until they do I will never buy a Windows Mobile device, not when there is the iPhone, now with binary SDK available for 3rd party developers. (The 30% commission requirement only ups the quality requirement for the third parties.)
    • Q: What if a different, solid commercial database was built versus Microsoft SQL Server?
      • A: It might be called Oracle, which is butt-ugly and has a cuture of its own full of down-trodden people who don't smile.
    • Q: What if someone open-sourced a complete database server for production web and entrprise apps as free alternative to SQL Server?
      • A: It might be called mySQL, which is feature-incomplete, and until recently lacking in administrative tools worth touching with a ten foot pole.
      • A: It might also be called Firebird, and although it has the maturity timescale and featureset of a complete DB, it also lacks the polish, usability, documentation, and presentation that geeks of today demand. (That or maybe I just don't like their web site.)
    • Q: What if Microsoft built a tiny-scale, .NET-based version of their SQL Server product?
      • A: It would be called SQL Server Compact Edition, and it would suck (meaning, lacking of features and being generally non-innovative)
    • Q: What if someone built a tiny-scale, native database engine that could be used anywhere?
      • A: It would be called SQLite, and although it rocks, it is a half-baked solution with no associated administration tools or C# managed API hooks in its core implementation.
    • Q: So what if someone built a Microsoft SQL Server look-alike, with decent performance, deep joins, T-SQL transactions, T-SQL sprocs, triggers, and managed assembly plug-ins, all in managed code, and with elegant administration tools, and produced it into a small compiled codebase that can be deployed on anything from medium scale web or enterprise apps to tiny-scale mobile applications?
      • A: It would be called VistaDB, and Microsoft should be astounded, if not absolutely frightened.
    • Every time I see another search indexing technology show up on Windows, I moan. "Index Server". "Office Search". "Microsoft Search". "Desktop Search". "Microsoft Search Server". For goodness sake, come up with and standardize on a solid API already!!
    • Apache Lucene is a blazingly fast text indexing software library. It can be used as a super-fast alternative not only to Google but also SQL Server.
    • Apache Solr, a server implementation around the Lucene search engine, is to search technology is what, say, early iterations of mySQL might have been to SQL databases. It is a buggy but functional demonstration of a complete and rediculously powerful data indexing and querying engine that can be used with both REST and JSON queries.
    • Microsoft Search Server is just a stupid pre-fab web page, a Googlish front-end to a spidered web site, proof that Microsoft just doesn't get it. Microsoft's indexing strategy is limited to file scanning and reproduction, a la Nutch. Microsoft clearly hasn't figured out how technologies like Lucene can render database engines like SQL Server's Full-Text Indexing obsolete.
  2. jQuery and the tersed Javascript community
    • Where jQuery shames Microsoft is where it also shames some of the other Javascript libraries. jQuery is to Javascript and DOM objects what LINQ is to C# and database objects, XML, and managed objects. It trivializes querying them, collecting them, calling on them, and performing operations on a group of them in one line of execution code (without a for loop).
    • The team that jQuery shames is not the LINQ team, but rather the ASP.NET AJAX team that implemented the Javascript framework. (A nice job they did, by the way, but heck, jQuery shames everybody!) See, Javascript already has a language community and culture, like C# and Java have community and culture. The Javascript community favors terseness and shortcuts by way of minified libraries that do much with little effort. Even in the simplest sense, this might mean short, terse, lower-cased code. Microsoft favors Pascal Casing and long namespaces. They went halfway and shortened the "System" namespace in Javascript to "Sys", but it still uses long, Pascal-Cased namespaces and OO-esque coding style rather than terse functional programming coding style.
    • Part of the terseness and "easy calling" approach pursued by the Javascript community is the simplistic approach of using one-liner databinding of HTML forms to REST URIs. The same community also typically interoperates with an MVC-oriented server architecture like PHPCake or Ruby On Rails. ASP.NET AJAX's approach, meanwhile, is to maintain viewstate and pass everything including the kitchen sink in a slow, klunky ASP.NET page postback lifecycle that could, and should, be cleaned up with a RESTful WCF / MVC AJAX view lifecycle.
    • Any time a corporation makes a commercial product that sells well and is very innovative but is being purchased primarily as a workaround for a failure of Windows or other Microsoft product, it brings awful shame upon Microsoft. In this case, the shame is the failure on Microsoft's part to support unencrypted QAM on Windows Media Center.
  3. Microsoft's own Xbox Live Dashboard / Marketplace -- Hello, Windows Team??
    • No competing technology platform has trivialized the usefulness of Microsoft Windows like Microsoft's own Xbox Live Dashboard and Marketplace. This was a hugely missed opportunity that Microsoft completely overlooked, whereby the rich, consolidated, packaged user experience that is enjoyed on the Xbox 360 could be transferred to the Microsoft Windows platform.
    • Web pages (@live.com) don't cut it. Putting Microsoft Downloads on Silverlight doesn't cut it. You have a rich Presentation Foundation on Windows that could have been used to deploy rich interactive experiences, as well as even rediculous DRM functionality built into Windows Vista, why isn't all of this being featured in Windows Ultimate?!
    • Valve's Steam cuts it for the game side of things, but lacking the WPF wow and full-screen experience that Microsoft could have introduced, and lacking the media purchases and downloads, it isn't enough.
    • Windows Media Center (which, by the way, I do use several hours every single day) would have cut it, if only it natively and more seamlessly supported the same package-extensibility featureset, marketplace integration, and Games category where marketplace demos can be downloaded and played, that are enjoyed on the Xbox.
  4. SVN (added 4/19/2008)
    • Nothing makes it seem to the software community more so than SVN that Microsoft "knows" software from only the confines of their own innovations and culture. On this technology alone, it sometimes seems like they live in a box and engineer in a cave.
    • Visual Source Safe is not version control. It's change control. The difference is as much cultural as it is functional; think a bunch of productive engineers in an agile group ("update", "OK, merged"), versus a bunch of wedgie-suffering tightwads in a red tape overwhelmed corporation ("can you please check that in so I can edit some of the code?")
    • I tried and failed to install Team Foundation Server three times and never got it right. The list of steps is a full page long, and each step takes several minutes of installing stuff -- set up Windows, figuring out whether or not to set up Active Directory, set up SQL Server Std. (not any version but Standard!), set up Windows SharePoint (don't confuse it with Office SharePoint! Don't confuse the version number!), optionally configure SharePonit for Active Directory, etc., etc. In the end, I always had something up and running, but when I would go load the SharePoint intance up in a web browser it would give me some stupid IIS error. Was I not supposed to hit it with a web browser? I don't know; the Help file didn't say.
    • I don't consider mysef a genius, and I don't consider myself a moron either. I consider myself having slightly-better-than-average intelligence. I think my I.Q. was measured 115 when I was a kid, whoopty doo. But I can set up SVN server and SVN client (w/ TortoiseSVN) without a lot of effort, as well as a few free issue tracking web sites like Gemini. I don't have Visual Studio integration (but you can use Ankh or Visual SVN), but I do have version control and a tracking system.
    • This blog post is very telling of the whole cultural situation over there in Washington.

Notice that I didn't mention things like mySQL, Ruby, PHP, Apache Web Server, Flash/Flex, Java, or Ubuntu Linux as key items on the list. All of these, while in some cases being innovative and even heavily used, simply don't match up with the depth of features, usability, and/or stability of those mentioned above. mySQL is a half-baked wannabe, Rail's founder presents himself to supporters having "constructive criticism" with a big "F*** YOU" on the overhead projecter, PHP is at a technical level no more special than ASP Classic using Javascript, Apache now needs to contend with IIS 7, Flash/Flex has been ousted (for its toolset) by Silverlight, Blend, and Visual Studio, Java has been beaten by C# / .NET, Ubuntu is just another Linux distro that wants to mean something special but comes up short (yes, even with Compiz-Fusion). They're good, but not good enough to bring shame upon Microsoft, or else Microsoft has finally managed to catch up, and get a little ahead.

kick it on DotNetKicks.com

Quick Install For Northwind Database

by Jon Davis 4. April 2008 00:18

Hmm.. I haven't used the Northwind sample database in quite a while. Tonight I discovered Northwind and "pubs" are both out of sight and out of mind as far as Microsoft is concerned; they're focusing entirely, 100% on AdventureWorks these days.

So be it, but I needed Northwind. Finding it wasn't particularly easy, and once I ran the .msi I didn't know where it went. Being as I'm using SQL Server 2005, and Northwind's life ended with SQL Server 2000's lifespan, I was worried it installed to nowhere. Turned out it went into a folder in "C:\SQL Server 2000 Sample Databases".

But here, I'm making available the one and only script that you need here: instnwnd.sql

Currently rated 5.0 by 5 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: ,


Powered by BlogEngine.NET
Theme by Mads Kristensen

About the author

Jon Davis (aka "stimpy77") has been a programmer, developer, and consultant for web and Windows software solutions professionally since 1997, with experience ranging from OS and hardware support to DHTML programming to IIS/ASP web apps to Java network programming to Visual Basic applications to C# desktop apps.
Software in all forms is also his sole hobby, whether playing PC games or tinkering with programming them. "I was playing Defender on the Commodore 64," he reminisces, "when I decided at the age of 12 or so that I want to be a computer programmer when I grow up."

Jon was previously employed as a senior .NET developer at a very well-known Internet services company whom you're more likely than not to have directly done business with. However, this blog and all of jondavis.net have no affiliation with, and are not representative of, his former employer in any way.

Contact Me 

Tag cloud


<<  May 2021  >>

View posts in large calendar