• Thanks to all, I got this solved. I have assigned a GUID to the temp table name and built/select/drop it dynamically. I have tested it and it is working perfect.

    Once again thanks everyone.