temp table belongs only to @@SPID?

I created a temp table, but another user is not able to go to tempdb and see the table- how can I  help her to see the table?

thanks
LVL 6
anushahannaAsked:
Who is Participating?
 
ralmadaCommented:
No, I don't think that's possible. I would suggest you create a regular table if you want multiple users to access it.
0
 
anushahannaAuthor Commented:
OK- so even though it is in tempdb, it will show up only in the original SPID - if you happen to close that window, then even the author can never reach it?
0
 
ralmadaCommented:
Yes, that's right. One the session is closed, you cannot retrieve it.

Just to clarify, you have two types of temp tables. local temp tables, that are only accesible in the module it was created, and global temp table that are accessible only in the session that creates them. That means that no other sessions (for example another user logged in) can access it.

0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
anushahannaAuthor Commented:
you  mean #temp and ##temp, right? ## is global?
0
 
ralmadaCommented:
yes, that's right :)
0
 
anushahannaAuthor Commented:
thanks as always, ralmada.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.