create procedure proc1 (@a int)
as
begin
if @a=1
create table #temp(a1 int)
else
create table #temp(a1 int)
end
while executeing the above code it shows error
like '#temp already exist' .why it shows an error?
Answer Posted / utpal chakraboarty
Because, Stored procedure is pre-compiled language.
Is This Answer Correct ? | 4 Yes | 12 No |
Post New Answer View All Answers
Describe and explain about SQL native client?
What to perform pattern match with the like operator?
Explain what is meant by replication of database?
Define Business Edition in SQL Azure?
How will you decide the active and passive nodes?
What is inline variable assignment?
Why and when do stored procedure recompile?
Where do you find the default Index fill factor and how to change it?
What are the encryption mechanisms in sql server?
In what sequence sql statement is processed?
What are the disadvantages of merge replication?
I applied Transactional with updatable subscriptions replication on 2 tables now i want to delete those 2 tables but i cannot delete those tables as replication is running how can i stop replication for those 2 tables(but i don't want to delete those replicated tables but i need to stop the replication) how can i do that
how can u get last observation in an unknown dataset ?
How to Check if table exists in sql server?
Can We Use Data-grids For Our Report In Ssrs?