Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2001-12-29 : 12:13:44
|
| Jose writes "I am trying to put the sp_who result into a table or cursor but I do not know how could I do it.Thank youJose" |
|
|
skillile
Posting Yak Master
208 Posts |
Posted - 2001-12-29 : 13:50:42
|
| create table #t ( field1 varchar(50), field2 varchar(50), field3 varchar(50), field4 varchar(50), field5 varchar(50), field6 varchar(50), field7 varchar(50), field8 varchar(50) )--make the fields the correct datatype and length--but this should do the trickinsert #t exec sp_whoselect * from #tdrop table #tslow down to move faster... |
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2001-12-29 : 15:02:36
|
| You could also look at sp_who and pick out the values that you need and use those rather than running the whole SP.An example of doing this with some extra features is at www.nigelrivett.comsp_nrlocks==========================================Cursors are useful if you don't know sql.Beer is not cold and it isn't fizzy. |
 |
|
|
|
|
|