Primary keys and clustered indexes

Primary keys and clustered indexes are two distinct concepts that often get mixed up with one another, but it’s important to understand the difference between them in order to build robust, performant SQL databases.

Dead simple Ajax

Ajax boilerplate is a pain to write. If you’re already depending on a large JavaScript framework, chances are you don’t have to think about it. But if you’re not, it’s unfortunate to have to add a reference to jQuery or a similar library just for the Ajax.

An ESLint starter kit for React development

Linting is essential to writing good JavaScript, and ESLint is, for my money, the best JavaScript linter out there at the moment. It’s super flexible, and also has plugin support which allows for features like ReactJS linting. For those starting a new ReactJS project, or those who want to integrate ESLint into an existing one, here is an .eslintrc (configuration) file to get you started.

Inlining table-valued functions in SQL Server

Table valued functions in SQL Server are great for writing DRY SQL code by encapsulating commonly-used snippets of database logic. However, in some cases they can be at the root of serious performance problems. Let’s take a look at an example of this. Say that we have a table that looks like the following.