Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Creating temporary table
Message
From
04/02/2014 14:16:00
 
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Environment versions
SQL Server:
SQL Server 2008
Application:
Web
Miscellaneous
Thread ID:
01593184
Message ID:
01593195
Views:
37
>The temporary table is created in the TempDB database under unique name for the session. So, you can create temporary table with the same name in two different sessions. This is for local #temp tables. If we're talking about global temp table ##temp then this table is shared by all sessions created after the session that created that global table.

I really cannot it under TempDB. Where exactly in that branch is this suppose to be?

Also, I guess I would need to verify to delete it if it exists, as you suggested, as well as regular deletion at the end of the command, which will be the normal case. So, the table will only exist for a fraction of a second if I understand correctly. I am not sure about performation issue as we are creating something on disk then. Is that correct?

>You may want to check this interesting article by Peter Larsson
>
>http://sqlblog.com/blogs/peter_larsson/archive/2009/10/15/performance-consideration-when-using-a-table-variable.aspx

Thanks, I will check it out.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform