![sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow](https://i.stack.imgur.com/WRK4V.png)
sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow
![sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow](https://i.stack.imgur.com/M7KbU.png)
sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow
![sql server - How to make variable update for each instance of for-each loop? - Database Administrators Stack Exchange sql server - How to make variable update for each instance of for-each loop? - Database Administrators Stack Exchange](https://i.stack.imgur.com/au9jE.png)
sql server - How to make variable update for each instance of for-each loop? - Database Administrators Stack Exchange
Welcome To TechBrothersIT: How to Create Tables Dynamically from Flat Files and load Data in SSIS Package - SSIS Tutorial
![sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow](https://i.stack.imgur.com/zGzCO.png)
sql - Using foreach loop container to create new columns in a table- can't solve "incorrect syntax near '@P1'" error - Stack Overflow
![sql server - SQL, foreach-loop-like INSERT based on inserted value that need to be re-selected, possible? - Stack Overflow sql server - SQL, foreach-loop-like INSERT based on inserted value that need to be re-selected, possible? - Stack Overflow](https://i.stack.imgur.com/2TG1I.png)