on 2012 Jun 04 2:52 PM
Hi All,
thanks in advance, i have a proc that create a #table ex create #table(myid int,myname varchar(10))
now i do a insert into thsi table from another view inside my proc
later i do a select from this table and that is where the proc thows a error that the table does not exists
it occurs on rare occasions otherwise the proc works fine
can anyone help to understand why this happends at a rare occassions when table is actually created inside this proc and used
Thanks kishore
Request clarification before answering.
If you use DECLARE TEMPORARY TABLE, or implicitly create a table via SELECT INTO, then the table's scope is the life of the block in which it's created - but if you use CREATE TEMPORARY TABLE, then the temporary table has connection scope and lives for the life of the connection (and hence across procedures).
So - to answer your question we'll need to see the exact code you're using.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
9 | |
8 | |
6 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.