MSSQL, bugs and a "patch"