Hi All,

Recently i came across this issue where temp tables in different sp’s having same name gave me an error when they are used together (calling other SP in a SP). I have created the scenario to explain this.

If you look at the issue it says the tabel in SP sproc1 is having issue with the insert statement,but when you try to execute the sproc1 individually it executes without any errors.

Make sure when you are calling some other Stored Proc in your current Stored Proc they don’t have any common temp tables names.

Any comments to explain this scenario further will be helpful.



Syed Asrar Ali

Like us on FaceBook Follow us on Twitter

Join the fastest growing SQL Server group on FaceBook