If you want to do it dynamically better to use Procedure for that .