Notes on SQL

Random articles from a puzzled DBA

For several years I have happily relied on @@IDENTITY to return the latest identity of a row when inserting data. However, I have started using the OUTPUT clause and have discovered the entertainment to be had in getting the latest identity when writing to two or more tables with what can appear to be one …

Continue reading

I take notes all day long as I work with SQL Server. Short scribbles, brief explanations, small novels – all committed to paper or some electronic format as I go through my professional career. The theory is sound and generally quite useful. Then I find I have so many notes that I have trouble actually …

Continue reading