I have a "Execute SQL task" in IS 2005 and it is placed in a foreach-container. For each iteration I want it to truncate a different table. The tables to truncate is specified in a variable at runtime.
In SQLtask_general.jpg you can see the settings of the general-tab and in SQLtask-parameterMapping.j
pg you can see the settings of my parameter mapping.
When i execute the task I get the following error:
[Execute SQL Task] Error: Executing the query "TRUNCATE TABLE @tablename" failed with the following error: "Incorrect syntax near '@tablename'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.
Does anybody know if/how it is possible to pass a parameter to my SQL-task?