FxCop for SQL Server - SQL Server Database Analysis Tool for Potential Issues

Is there a tool that can analyze SQL Server databases for potential problems?

For instance:

  • foreign key column that is not indexed
  • index in a column uniqueidentifierthat does not haveFILL FACTOR
  • a LastModifiedDate DATETIMEwhich does not have a trigger UPDATEfor updating datetime
  • large index with high fragmentation
  • unfragmented index that exists in several extents
  • a trigger that does not contain SET NOCOUNT ON(leaving it suspicious for "the trigger returned a result set and / or worked with SET NOCOUNT OFF, and another outstanding result set was active.")
  • database, table, stored procedure, trigger, view created with SET ANSI_NULLS OFF
  • a database or table withSET ANSI_PADDING OFF
  • database or table created using SET CONCAT_NULL_YIELDS_NULL OFF
  • a highly fragmented index that can benefit from a lower FILLFACTOR(i.e. more additions)
  • a table with a very wide cluster index (e.g. uniqueidentifier + uniqueidentifier)
  • a table with a unique clustered index
  • use text/ntext, notvarchar(max)/nvarchar(max)
  • use varcharin columns that may contain localized rows and should be nvarchar(e.g. Name, FirstName, LastName, BusinessName, CountryName, City)
  • use *=, =*, *=*, not LEFT OUTER JOIN, RIGHT OUTER JOIN,FULL OUTER JOIN
  • trigger that returns a result set
  • , timestamp, rowversion
  • timestamp
  • image, varbinary(max)
  • ( 100x )

FxCop SQL Server?

. Microsoft SQL Server 2008 R2 . p >

+5
5

SQLCop - !

enter image description here

+8

Static Code Analysis ( , VS- FxCop), Visual Studio Premium Ultimate, , , . , , .

+2

. .

, , T-SQL - , , , .

" " - , , . , . . http://code.google.com/p/caderoux/source/browse/#hg%2FLeversAndTurtles Windows Forms, , T-SQL.

+1

SQLCop. , FXCop.

+1

All Articles