tags:

views:

127

answers:

1

Can I write a select statement where the from clause has a scalar variable which contains table name ? Actually I want to write a store procedure that will take table name as input and display percentage of nulls in that table.

thanks

+4  A: 

No, you will have to build the statement as a string and call sp_execute on it.

Otávio Décio