@TABLE_NAME NVARCHAR(100) SELECT * FROM @TABLE_NAME END
create procedure dbo.myProcedure ( @tablename nvarchar(100) ) as Declare @Stmt nvarchar(max) begin Set @Stmt = 'SELECT * FROM ' + @tablename Exec (@Stmt) end
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)