SQL Server Performance Forum – Threads Archive
ARRRG!!
Question. I thought Microsoft was going to fix the "select into temp table in a proc" issue it has had in SQL2005 SP2. I guess not. Any ideas as to if this will ever be fixed or is it a "feature"?Michael
MCDBA "The fear of the Lord is the beginning of knowledge,
but fools despise wisdom and instruction." Proverbs 1:7
what’s the issue exactly? is there a kb article about it? www.elsasoft.org
I probably missed this thread because it was posted in an RS forum. As jezemine already asked, care to explain your exact issue? —
Frank Kalis
Moderator
Microsoft SQL Server MVP
Webmaster:http://www.insidesql.de
if you have any proc that has a select into temp table then it will not allow you to use that proc (you will get an error – "There is
an error in the query. Invalid object name ‘#TempTable’."). Crystal has no problem with this. It is just irritating. You have to use a table variable that sometimes is faster – sometimes not. Once you get it running with the table variable, you can change it back to a select-into for the proc and it wont know the difference. Just a hassle. Michael
MCDBA "The fear of the Lord is the beginning of knowledge,
but fools despise wisdom and instruction." Proverbs 1:7
Instead of SELECT INTO, did you try CREATE TABLE #tmp and INSERT INTO #tmp SELECT syntax?
The CREATE TABLE…INSERT INTO… combination should be preferred anyway. Causes less trouble with recompilation and locks. Though it’s more to type. [<img src=’/community/emoticons/emotion-1.gif’ alt=’

]]>