Fastest Updates in SQL Server

The project I’m working on at the moment requires me to achieve the fastest updates I can into a moderate sized SQL Server database table. My initial attempts were adequate for the testing I was doing on my development machine but when I came to do a more thorough test in a production like environment I found that the method I was employing wasn’t even close to fast enough. At that point I seriously considered just giving up, the difference between what I had and what I needed didn’t look like an “I’ll give it a tweak” type problem¬†it was a vast performance gulf that had to be crossed. The solution was to better understand both my application and SQL Server and here’s what I did.Continue reading

MySQL Triggers and UUID

One of the applications I maintain currently only runs against Microsoft SQL Server. For the most part this hasn’t proven to be that much of a problem as everyone who uses the application also runs MS SQL. The problem comes when I want to deploy and test it on one of the company servers because they all run Linux and there is no way to run MS SQL under Linux (see note 1).Continue reading

SQL Having

The having clause is used when filtering has to be performed on aggregate functions since the where clause can not be used in this situation. Since the having clause is often used in conjunction with the group by clause the examples on this page use the same data as was used in the group by article and follow on directly from that article.Continue reading

SQL Group By

The group by statement is generally used in conjunction with the various aggregate functions in order to produce results that are grouped by one or more columns. This is a very powerful way to report results for groups of results that share some common trait – in the example below the shared trait we are using is generally customer name.Continue reading