Microsoft SQL Server

Sample User Authentication Database Schema

My User/Password Database Schema for Business Applications When I first bumped into the built in ASP.Net User Authentication Provider, I lived for a couple of hours in bliss thinking to myself “that’s convenient, I’ll never have to worry about the user authentication portion of my websites and business applications again” — until I tried to [...]

HOW TO: Print-off a SQL Server 2008 Database Schema

This particular project was a lot of fun, because it reminded me just how much I love LINQ, and not just as a substitute for SQL

My Email Schema in SQL Server 2008

Here is the SQL Server script for creating my simple Email Database for the samples I will be blogging about on this site. The schema is documented here. And, sooner or later, I’ll post SQL scripts for other languages as well. Dont forget to check out the Pro’s and Con’s for using SQL Server to [...]

Initial thoughts on ASP.NET MVC

This blog entry is entirely abstract, no code whatsoever.  And it contains opinion.  If opinion offends you, or if you only want functional code to play with, this entry will probably just frustrate you. That said, my topic of discussion is the new MVC option for ASP.NET. The Model View Controller Framework: Brought to You [...]

How to select something “from dual” in a non-Oracle database

What is the dual equivelant in Postgres, MySQL, Sqlite, or Ms SQL Server? I had someone ask me yesterday what Sqlite calls the dual pseudotable (for those who don’t know, dual is a heavily used, Oracle specific concept). I started at him blankly for a minute and thought how best to answer without laughing. But [...]

Inserting multiple rows in one SQL statement

Background So, the other day, I opened up a MySQL dump file just to graze over it and see how they did things (you can call be weird if you want to, I prefer to think of it as “curious”). Anyway, I noticed something very cool that I thought was absolutely ingenious. They were inserting [...]

Comparison of Auto Incrementing Primary Key feature in several SQL Dialects

The Problem The whole point in using SQL to interact with a database is for developers to be able to use the same basic language to interact with any database. The intentions were good but, as it turns out, even something as universally desired as having a primary key that automatically increments itself is not [...]