I have try to use statement below in my SQL. Is it possible by any means to dynamically select table form database. (For example select table name from Comobox and then display data from selected table)
SET @var1 = 'test';
SELECT * From @var1
I have try to use statement below in my SQL. Is it possible by any means to dynamically select table form database. (For example select table name from Comobox and then display data from selected table)
SET @var1 = 'test';
SELECT * From @var1
Dynamic SQL requires that you create a string consisting of the sql statement, and then you execute the string. Dynamic t-sql quotes in string