• Technologies

  • Instructors

  • Blog Author Archives: Jeff Jones

    Renaming SQL Server

    The following is a T-SQL script you can use to rename your SQL Server after you have changed the computer name. This script will work if you are connected to the default instance or a named instance. After running the script, you must restart SQL Server for the action to complete. DECLARE @machinename sysname, @servername … Continue reading Renaming SQL Server

    Accessing Master Sysperfinfo Table in SQL Server

    The SQL Server 2000 statistics are available in a pseudo-table in Master called sysperfinfo. This table returns the statistics in a table format. There are some statistics that represent ratios (i.e., Buffer Cache Hit Ratio). These statitics must combine two rows. One row provides the data value and the second row provides a divisor. Therefore … Continue reading Accessing Master Sysperfinfo Table in SQL Server

    SQL Server 2005 OVER Clause

    One of the features of SQL Server 2005 that does not get a lot of press is the new window-based calculation clause called OVER. You can now generate different aggregates with different grouping columns in the same query, without having to use subqueries. This is especially useful when you need to include aggregated values along … Continue reading SQL Server 2005 OVER Clause