Miscellaneous SQL Server Optimization TipsAugust 6, 2002 When you perform a backup, some SQL Server commands cannot be made, for example: during a backup you cannot run ALTER DATABASE statement with either the ADD FILE or REMOVE FILE options, you cannot shrink a database, you cannot run a CREATE INDEX statement, you cannot make SELECT INTO, bulk load and so on. So, to improve backup performance, you can perform backups on the local hard disk first, and then copy backup file(s) to the tape later.
The nonlogged bulk copy is much faster than the logged one, but to use it you must provide all the following conditions: This can improve performance in comparison with the character mode.
The BULK INSERT command is much faster than bcp or the data pump to perform text file import operations. However, the BULK INSERT statement cannot bulk copy data from SQL Server to a data file.
The bcp utility is much faster than DTS, so try to use it whenever possible.
This can be used to prevent deadlocks.
This can improve performance of your select statements.
A table is in third normal form (3NF) if it is in second normal form (2NF) and does not contain transitive dependencies. In most cases, you should normalize your tables to the third normal form.
Normalization to the forth and fifth normal forms can result in some performance degradation, so it is sometimes necessary to denormalize your database's tables to prevent performance degradation.
This helps reduce the table's size, which can improve the performance of your queries and some maintenance tasks (such as backup, restore and so on).
Because SQL Server stores text/ntext columns on the Text/Image pages separately from the other data, stored on the Data pages, then it can take more time to get the text/ntext values.
Againt, this helps you reduce the table's size, which can improve the performance of your queries and some maintenance tasks (such as backup, restore and so on).
The char data type is a fixed-length data type and varchar data type is variable-length data type.
So, by using char data type, you can increase the probability of an in-place update instead of delete/insert or deferred update. The in-place update is the most effective method of modification; when it is used, the data is changed on its physical place. When the row's size is changed, the delete/insert modification method can be used. This does result in some performance degradation, though.
Using the TRUNCATE TABLE is a much faster way to delete all of the table's rows as it removes all rows from a table without logging the individual row deletes.
Binary sort order is the simplest and fastest sort order, but it is used less often due to the binary sort not being case-insensitive and being based on the numeric values (from 0 through 255) of the characters in the installed character set.
Because using Enterprise Manager is very resource expensive, use stored procedures and T-SQL statements, in this case.
Because domain controllers have extra overhead, you should install SQL Server on a standalone server box to dedicate all of the server's power to SQL Server.
|