Category Archives: Off-topic

Seriously off topic: What to do when a document has a mismatch of one and two spaces after the end of a sentence?

The grammar checker can be configured to flag this, but doesn’t provide a change all option, just a change!  The answer is to use regex in find and replace (Ctrl+H): Find what: ([.\?\!]{1} )([A-Z]{1})Replace with: \1 \2Options: Use wildcards Just … Continue reading

Posted in Off-topic | Tagged , , | Leave a comment

Obtaining a random result set in PowerShell

Given a set of data how does one return an arbitrary subset?  Well in T-SQL we’d do this: So how can we do this in PowerShell?  Well in pretty much the same way actually.  Pipe to Sort-Object and then to … Continue reading

Posted in Off-topic, Scripting | Tagged , , , | Leave a comment

Seriously off topic: Ignoring spelling and grammar in certain text styles in Microsoft Word

When writing detailed design and deployment guides I get frustrated by Word rightly having issue with the spelling and grammar of my PowerShell snippets.  It makes the Spelling and Grammar checker almost redundant, for example, in my 374 page detailed … Continue reading

Posted in Off-topic | Tagged , , , , , | Leave a comment

sp_executeSQL to the rescue

(a.k.a. my DEFAULT constraints aren’t working –NULL is being written to the DB.  Where are my default values?) I encountered a bug in a stored procedure I’d written that took me a little longer to fix than it should have … Continue reading

Posted in Off-topic, SQL Server, Troubleshooting | Tagged , , , , , , , , | Leave a comment

Seriously off topic: creating a semi-circle in Visio 2010

I wanted to depict the CS and MV as two halves of a circle (coloured differently) and I really couldn’t work out how to do it.  I found reference to the Fragment command but that is nowhere to be seen … Continue reading

Posted in Off-topic | Tagged , , , , , | 8 Comments