10 Things You Shouldn’t Do with SQL Server

I’ve seen and written too much stuff that violates these rules. Click the link after “Via” for the full article…

10. Add a Low Privilege Account to the Admin Role
9. @@IDENTITY vs. SCOPE_IDENTITY
8. Fetch Semi-static Data on Each Request of a Resource
7. Include SQL Data Manipulation Language in Application Code
6. Abuse SELECT *
5. Create Stored Procedures without Exception Handling
4. Prefix Stored Procedures with “sp_”
3. You Don’t Protect the Database Connection String
2. Accept All Input
1. Access the Database from the Application with the “sa” Account

[Via dotnet junkies]

RE: Dynamic Behavior with the Decorator Pattern

Here’s great example of how to use the Decorator pattern in C#….

The Decorator pattern is a means to transparently add responsibilities to another object on the fly.  In some cases it’s a simpler solution than creating additional subclasses through inheritance.  A decorator is implemented by creating a class that wraps access to another class.  The decorator implements the exact same public interface as it’s inner member.  That sounds like a lot of gobbledy-gook to me too, so let’s jump into a code sample.

Click here to see the full article.

[Via Jeremy D. Miller — The Shade Tree Developer]