If my stored procedure takes in a table name, how do I verify that that table exists?
I have tried everything under the sun, like this:
incoming variable is called @TABLENAME='BLAH'
if exists
(@TABLENAME) --Gives an error
if exists
(Select * from @TABLENAME) --gives an error
if exists...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.