Category: Code
This area of the site is dedicated to code snippets for quick and easy reference
Ektron Metrics – User Count By User Group
Part of the Ektron Metrics Script, this query will help with metrics to give you an idea of how often your users login.
Battery Life
By its self this code is rather simple and meaningless but useful when adding to scheduled tasks or applications that take a long time to run and have the potential of running on a laptop. Before using the code below in Design View you’ll need these: 1 Progress Bar 2…
Delete Duplicate Rows
Reference: http://blog.sqlauthority.com/2009/06/23/sql-server-2005-2008-delete-duplicate-rows/
Find Currently Running Query – T-SQL
Reference: http://blog.sqlauthority.com/2009/01/07/sql-server-find-currently-running-query-t-sql/
Find Most Expensive Queries Using DMV
Reference: http://blog.sqlauthority.com/2010/05/14/sql-server-find-most-expensive-queries-using-dmv/
Get Latest SQL Query for Sessions
Reference: http://blog.sqlauthority.com/2010/05/05/sql-server-get-latest-sql-query-for-sessions-dmv/
Last Read / Last Write
Sometimes you need to know the last time a table or database was read from or written to, this code will help determine that for you. Originally Found At: http://blog.sqlauthority.com/2009/05/09/sql-server-find-last-date-time-updated-for-any-table/
You must be logged in to post a comment.