Modified SP_who

Here is a modified SP_WHO procedurewhich returns more information about the current session.I forgot all the thing that i have added to the sproc, but the last addition shows the last executed TSQL statement.There might be a better solution to get the values from DBCC rowset, thou I did not have time to think everything […]

2002-05-28

674 reads

Procedure for Random Numbers

Here is handy procedure to generate random number.I find it useful when I generate large amount of test data in a database.For example if you need to create a Customer Data and what they have purchased in the last month to run perfrmance tests on large amount of data an set up necessary indexes.You can […]

2002-05-13

589 reads

Cursorless Cursor

Here is as sample of implementing cursor.In some cases my tests showed that this approach performs better than native cursors in SQL Server.All you have to do is move the dataset into a temp table with a new Identity column and then use a simple loop to extract the data as you would do normally […]

4.5 (2)

2002-05-06

1,911 reads

Blogs

Everyone Run a SQL Saturday in 2021

By

With SQL Saturdays being rebooted, and the SQLSaturday.com website live, it’s time for events....

Modern Data Warehouse & Reverse ETL

By

An extension to the Modern Data Warehouse (MDW) that I have heard a bit...

Daily Coping 12 Apr 2021

By

I started to add a daily coping tip to the SQLServerCentral newsletter and to...

Read the latest Blogs

Forums

How to check latency for user database.

By sizal0234

Hi, One of the user databases was in Not synchronizing / In recovery mode....

How to map out multi-level Supervisor/Employee relationship

By YSLGuru

No doubt this has already been answered and probably detailed many ways so I...

T logs increasing

By atulyan.aries

Hi In one of our servers the t-logs of one of the database which...

Visit the forum

Ask SSC

SQL Server Q&A from the SQLServerCentral community

Get answers